|
Maybe overriding CBN_SELCHANGE ?
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Where did you learn how to code Winsock, or in MFC CSocket. I would like to learn how, but I don't know where to start. Any pointers to where I should look?!?!?!
Thanks
-Ken Mazaika
|
|
|
|
|
Warreng Young's Winsock Programmer's FAQ is a valuable resource, and includes some links to tutorials.
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
see " visual c++ menu bar: Ctoolbar, CDialogBar, or others? " below, i answer ur question there.
cheers
includeh10
|
|
|
|
|
1 search google + buy books
2 write code
3 goto 1
Len Holgate
www.jetbyte.com
The right code, right now.
|
|
|
|
|
Hi,
How to change the font for a CStatic control and others (CListBox, CEdit, etc.) on a dialog based application ?
I tried this with a CStatic control in the OnInitDialog event:
CFont font;
font.CreatePointFont (72, _T ("Arial"));
GetDlgItem(IDC_STATIC)->SetFont(&font);
but it didn't work.
Thanks
|
|
|
|
|
The problem is that font gets destroyed when the function where it was declared exits. Store it as a member variable of your dialog instead and things will work (hopefully).
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Hi, I would like to learning Thread Process, Synchronize datas between multi Thread processing.
I would like to buy a book for beginner with schematic or finding some sample very explicite for understanding this.
Best Regards
youssef
|
|
|
|
|
cope all of vc samples from vc disk, then do a search about functon: CreateThread, u will find a lots u need.
here is first place to go before spending ur unlimited dollars
cheers
includeh10
|
|
|
|
|
Best recommendation is the "the" book about system programming: Jeffrey Richter, "Programming Applications for Microsoft Windows", ISBN: 1572319968.
This book covers all about threads, processes, synchronisation, memory management, DLLs and much more. It does this a pure API-centric way (no MFC, ATL or similar stuff) in C/C++.
--
Daniel Lohmann
http://www.losoft.de
|
|
|
|
|
Check out 'Win32 Multithreaded Programming' by Cohen & Woodring, available on O'Reilly press. It covers both Win32 API and MFC methods, and takes you from the very basics of threading right through to the most complex stuff; it's well presented and easy to follow too.
Dylan Kenneally
London, UK
|
|
|
|
|
Hi.
I have a propertysheet with a multiple propertypages. I would like get two functions working.
1) enable/disable default buttons (IDOK, IDCANCEL, ID_APPLY_NOW) in the propertypage.
2) be notified when the user navigate to and from different propertypage. If possible set the active propertypage programmically.
Okay. I believe this is the way to enable/disable the default buttons of a propertysheet from within the propertysheet.
-----
// disable the OK button
GetDlgItem(IDOK)->EnableWindow(FALSE);
-----
However, the code above does not work from within a propertypage. Is there a way to accomplish the above without sending a message to main frame?
I have no idea on what message to catch as the user navigates to and from propertypages.
Thanks,
Kuphryn
|
|
|
|
|
I guess this should work:
GetParent()->GetDlgItem(IDOK)->EnableWindow(FALSE);
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
|
i need to create a menu similar to visual c++ menu: can drop buttons on it and more.
i am sure vc menu bar is not common menu, but i don't know what exactly it is: based on CToolBar, CDialogBar or others, and how to implement it.
do u have sample or idea?
thx
includeh10
|
|
|
|
|
I'm not exactly sure what "can drop buttons on it and more" means, but I think all it is, is an owner-draw menu, thats coded to be more interactive. I could be wrong...probably am.
-Ken Mazaika
|
|
|
|
|
thx, but u r ..., things are not so easy.
if u want to learn socket, copy all of vc samples to ur hard disk from cd, then do a search (from vc 'search in files') for CSocket. u can find what u need: easy to learn. but the sample includes 2 parts: server and clint, find both. u will learn in several hrs if u r not a beginner for MFC.
cheers.
includeh10
|
|
|
|
|
in a program, i display several (can be any more) modeless dialog boxes, those dialogs may be overlapped each other.
when user moves mouse over dialogs, i need to do different operations for each one according to their z-order.
top dialg is easy to handle because it has mouse msg, but how to know z-order for others?
thx
includeh10
|
|
|
|
|
If the dialogs have a common parent, you can use EnumChildWindows to list them according their Z orders.
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
thanks a lots.
i never use the function before.
u mean, for a special dialog box, it may be second from topmost or third or any, the function can detect the 'number'?
note: the number is changed by mouse click dynamically, not by creating.
hope get ur opinion before my testing.
includeh10
|
|
|
|
|
It is not as simple as you'd wish, you'll have to work out your way from what EnumChildWindows does. This function calls repeatedly a callback function provided by you listing all child windows according to their Z order. In your callback you'll have to compare what you're given with the dialogs and use that info to assign them the corresponding Z "number".
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
quite easy if it is.
thx
includeh10
|
|
|
|
|
Its awesome! I'd been popping up clunky messageboxes which sometimes caused me grief while debugging. TRACE is just too cool. I'm sure theres a lot of debugging tricks one can employ with TRACE.
ns
|
|
|
|
|
Kewl! Don't forget to also use ASSERT liberally!
/ravi
Let's put "civil" back into "civilization"
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
And if you're ever not using MFC, you can use OutputDebugStr anywhere you like.
Christian
come on all you MS suckups, defend your sugar-daddy now. - Chris Losinger - 11/07/2002
|
|
|
|