|
Run MSDEV with the /USEENV command-line switch. See the page "Building a Project from the Command Line" in the docs for more info.
--Mike--
http://home.inreach.com/mdunn/
#include "buffy_sig"
|
|
|
|
|
Thanks, that was what I was looking for!
|
|
|
|
|
Hi,
I want to implement MS Word kind of Autocomplete tip functionality in my MDI application with CRichEditView.
MS Word kind of Autocomplete tip:- in Microsoft Word if you type date or month name, say Janu, you get a tool tip kind of box displaying January. Now to accept this you need to hit Enter key.
I want to give a feature similar to this, when user types, in rich edit view of my MDI application. How to do this?
Any pointers regarding this will be of great help!
thanks,
Shrini
|
|
|
|
|
you need to trap the wm_char type messages to track what the user types and have a look-up list of hot words or word parts ... when you find a match you can create an edit box (drop-list,tooltip window,whatever) at the appropriate place on the screen and display the list of possible matches for selection
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
How can I change the status of my ICQ from
another app, e.g. like "ICQ Control Center"
or "GameSpy" do?
Furthermore I'd like to set a custom message into
the Status
does anyone know a solution?
thanks in advance
|
|
|
|
|
speaking from the top of my head i would imagine they had figured out what message to transmit to the ICQ central servers to make it update its status ... you could packet-snoop your tcp/ip connection to see what it sends or i guess you could ask for the developer docs (if they are available)
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
Hello,
I'm new to this programming stuff and am having a problem with a SDI. I have created a program to append multiple text files into one. Everything works great except I can’t seem to display the text when I open a text file. I can open the text file and store the text from that file into a CString member variable. When I keep opening files my program keeps adding the text to the same member variable.. Then when I chose to write the contents of the variable to a text file every thing works fine.. This all works great but when I open the files and store them into the variable I don’t see the text on the screen in my program.. Like I said I'm new to this and its probably something dumb..
Any help would be appreciated..
THANKS!
Rob Jones
|
|
|
|
|
The point of the view is that you're able to manage how your data is displayed - nothing happens by itself in that regard. Drawing is done in OnDraw, or OnPaint. Whatever you output to the DC created in OnPaint ( or passed to OnDraw from OnPrepareDC ) is what you will see. Look up CDC::ExtTextOut for info on how to output text.
Christian
#include "std_disclaimer.h"
|
|
|
|
|
hi,
this is the deal.
I have a SDI application. and a sub-menu,,
when the user clicks on the sub-menu, the left click of the mouse should be activated for only one click.
thats all..
How can i do that. I'm able to activate the LBUTTON in the CView,
but i don't know how to do that right after the sub-menu is clicks.
I really appriciate your feedback.
ehsan
Ehsan Behboudi
|
|
|
|
|
I'm Sorry, but I don't understand what happens.
You can be clearer???
Cheers!!!
Carlos Antollini.
|
|
|
|
|
do you mean "how do i disable the menu item after it is clicked once" or "how do i set the focus to the right view after i click on a left-view sub-menu item" ... or something altogether different?
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
I'm making a dialog box - based application, and I want list boxes. I've generated a list box in the resource editor, and I want the simplest possible explanation of how to add and retrieve elements from/to it.
The MSDN lib didn't help me here at all.
I know there is a list box tutorial on this (excellent) site which starts out (too) "basic", but then skips the "how do I add or remove elements" part and jumps right onto periphere subjects such as "how to change list styles at runtime" and similar.
Not very useful, sorry..
I would really appreciate someone's help on this basic subject.
greetings,
Gustav Tresselt
= Gustav =
|
|
|
|
|
1) open your Visual C++ help/MSDN
2) select 'Index' tab
3) type CListBox
4) select 'class members'
One of the method is described as one that 'Adds a string to a list box'. Another 'Copies a list-box item into a buffer'. I'm leaving finding method names as an exercise
Tomasz Sowinski -- http://www.shooltz.com.pl
|
|
|
|
|
Thanks for a *very* quick reply! However,
the real problem is simple, but not that simple.
Here's what I added (to complement my listbox IDC_LIST1
from the Resource Ed)
My *Dlg.h-file; 'class CDekodLog : [..blabla..]',
--
Added: CListBox lst;
In the *Dlg.cpp-file: 'OnInitDialog':
--
Added: CRect rc; GetWindowRect(&rc); ScreenToClient(&rc);
lst.Create(WS_CHILD|WS_VSCROLL, rc, this, IDC_LIST1);
CString stri = "Per pusling";
lst.AddString(stri);
UpdateData(FALSE);
So far, so good? FINALLY; the DoDataExchange-routine;
--
Added: DDX_Control(pDX, IDC_LIST1, lst);
^^ This is my attempt to transfer the test-data stored in
the lst-object to the IDC_LIST1
(snipped from the ListBox-tutorial-source from this domain).
This results in:
a) Debug assertion failure, and
b) a fatal error which shuts down my app..
Thx again,
Gustav
= Gustav =
|
|
|
|
|
DDX_Control inside DoDataExchange assigns your 'lst' member variable to already existing Windows listbox control. You don't need to call lst.Create. Creation occurs before your code is executed. DoDataExchange is called from CDialog::OnInitDialog. Your calls to CListBox::AddString must be placed *after* CDialog::OnInitDialog, because the 'lst' variable has to be properly initialized by DDX_Control. One more thing - UpdateData(FALSE) is also unnecessary.
Generally speaking, you can do anything you want with your CListBox, but after CDialog::OnInitDialog. Adding and removing strings doesn't require calling UpdateData.
Tomasz Sowinski -- http://www.shooltz.com.pl
|
|
|
|
|
Thanks for another *very* swift reply!!
Now my source works, and I am [lim inf] grateful!
Quick sum-up of conclusions:
* Declare a CListBox-object somewhere
* Use the "DDX_Control" in DoDataExchange to initialize it
* Add/remove strings and it will be updated by the DDX_Control
each time you UpdateData()..
That really helped.. thanks again!
= Gustav =
|
|
|
|
|
One thing to remember: adding/removing strings does not require UpdateData. CListBox::AddString (as well as almost all other members of CListBox class) is just a thin wrapper around Windows message LB_ADDSTRING - your string will appear instantly on the screen.
Tomasz Sowinski -- http://www.shooltz.com.pl
|
|
|
|
|
Hello, the codegurus around the world.;)
To be sure, class wizard is a useful tool to decrease the developement time.
However, UpdateData(FALSE) tries to update all data which belongs to DDX function.
So, if we don't do this, not use UpdateData function.
Besides, GetDlgItem(ID NUMBER) also gets CWnd of each control, sometimes we don't need
to use class wizard at all.
As we write the code so much in VC++, we understand which cases we should use the class wizard or use just GetDlgItem().
At the beginner level, I think that he or she had better use GetDlgItem to understand how
we do the cast of each control CWnd and the other suffs.
Have a nice day!
-Masaaki Onishi-
|
|
|
|
|
Casting the return of GetDlgItem is a *bad* idea if you have the option of setting up a member variable that is of the correct type to start with. I would recommend that anyone using VC++ learn how to insert message handlers/variables without using the class wizard, because eventually you'll need to know how it is done, but once you know how to do it, there is no reason not to let the Class Wizard do the donkey work for you, in the same way that I believe anyone should write their own string class/array class/linked list class, but should still use CString/vector/list at the end of the day for most applications.
It can also be useful to call UpdateData without ever calling UpdataData(false), when we want to know values, for example this is how the radio button groups work, but do not want to change anything that needs to be sent back 'up the line'.
Christian
#include "std_disclaimer.h"
|
|
|
|
|
Hi all,
this may be a stupid mistake, but i got the following when using TransparentBlt:
error LNK2001: unresolved external symbol __imp__TransparentBlt@44
I tried including windows.h, wingdi.h, and using gdi32.lib (and combination of them).
Can anyone point out my stupidity?
|
|
|
|
|
You should link your project with Msimg32.lib.
Best regards,
-----------
Igor Soukhov (Brainbench/Tekmetrics ID:50759)
igor_soukhov@yahoo.com | ICQ:57404554 | http://siv.da.ru
|
|
|
|
|
Thank you very much.
|
|
|
|
|
After adding the decoding files of the eldos sound engine, i get following error :
fatal error C1010 : Unsuspected (or something End of file while seeking the directive for the precompiled header
and if i click on it i get to the end of the file ( } ).
What causes this error ? How can i fix it. I saw it work in another project but i dont know how to fix, so please help me.
|
|
|
|
|
Add this line into added .cpp files
/#include "stdafx.h"
Best regards,
-----------
Igor Soukhov (Brainbench/Tekmetrics ID:50759)
igor_soukhov@yahoo.com | ICQ:57404554 | http://siv.da.ru
|
|
|
|
|
Thank you so much !!!
now it works just perfectly.
|
|
|
|