|
-
Sep 14th, 2000, 10:30 AM
#1
Thread Starter
Addicted Member
Hello!
I started with VC++ and I'd need some help (greatly appreciated).
I use resources (dialogs) and I'd like to know how can I load another dialog through code 'cause I just can't figure it out. I've already looked in MSDN Library, but I found nothing useful.
Are there any MFC (and dealing with resources) tutorials? I've found some MFC tutorials, but none of them were including resources and dealing with them. Any suggestions?
Zvonko Bostjancic
Ilirska Bistrica, Slovenia
[email protected]
Using VS6 Professional with SP3
Programming mostly in VB and I've started to learn VC++ & MFC
-
Sep 14th, 2000, 02:26 PM
#2
Monday Morning Lunatic
If you're using MFC, right-click on the dialogue in the dialogue editor, and choose ClassWizard. It should ask you if you want to make a new class for it.
For non-MFC, use the CreateDialog function:
Code:
HWND hMyDlg;
if(hMyDlg = CreateDialog(hInstance, MAKEINTRESOURCE(IDD_MYDIALOG), NULL, DlgProc)) {
ShowWindow(hMyDlg, SW_SHOW);
}
Where DlgProc is your Dialogue Box Procedure (see the Platform SDK).
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Sep 15th, 2000, 12:16 PM
#3
Thread Starter
Addicted Member
Thanks.
But what I really want is that:
I have created dialog (in resources) and I want to show another dialog when user presses button on my main dialog. How can I do that, 'cause I've tried something but it didn't work out anything.
Zvonko Bostjancic
Ilirska Bistrica, Slovenia
[email protected]
Using VS6 Professional with SP3
Programming mostly in VB and I've started to learn VC++ & MFC
-
Sep 15th, 2000, 01:30 PM
#4
Monday Morning Lunatic
I'll send you an example project in a bit. You're on VC6, aren't you?
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Sep 15th, 2000, 03:41 PM
#5
Thread Starter
Addicted Member
Could you do this for me and send me an example?
I have VS6 (SP3).
My e-mail: [email protected]
Thanks.
Zvonko Bostjancic
Ilirska Bistrica, Slovenia
[email protected]
Using VS6 Professional with SP3
Programming mostly in VB and I've started to learn VC++ & MFC
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|