window handling

it is known that DialogBoxParam function work after you pass the ID control of window as a parameter but there is no ID control of window in visual studio .......need help??? (i know i can use createwindow function and use handles instead but it wont be accurate )
Out of interest, what won't be accurate? (about your windows?)

Last edited on
the shape of window and the position of buttons
You need to create a resource. Create a Dialog resource. In the order, their default IDs are: IDD_DIALOG1, IDD_DIALOG2... (You can click on the window in the editor and check the Properties tab).
In your inclusion file (stdafx.h or main.cpp depending on your programming style) you also need to include a new header you will find in the Solution Explorer. Then, when calling DialogBoxParam, you need to pass MAKEINTRESOURCE( /* Dialog ID Here */ ) as the id.
Note that Visual C++ Express editions don't support resource editing; you've got to pay for that!

Or use a separate resource editor. e.g. ResEdit
ResEdit is a resource editor for Windows programs. The original purpose was to help C++ developers to create resource scripts. Now it can also be used to modify any resource in PE files (exe, dll, ...) and compiled resource scripts (res files).

Last edited on
so that is why .... thank you was my biggest proplem
Topic archived. No new replies allowed.