Results 1 to 7 of 7

Thread: Showing a dialog boix

  1. #1

    Thread Starter
    Member
    Join Date
    May 2001
    Location
    US Of A
    Posts
    41

    Showing a dialog boix

    how to i show a dialog box i made in vc++, and my main app is made in mfc, if any one can help me with this it will be ever help full

  2. #2
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    In the dialogue editor, select "ClassWizard" from the right-click menu (on the dialogue). If it asks you to create a class answer yes (give it a reasonable name).

    Then you can just use something like:
    Code:
    CMyNewDlg newDlg;
    newDlg.DoModal();
    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

  3. #3

    Thread Starter
    Member
    Join Date
    May 2001
    Location
    US Of A
    Posts
    41
    so the function is domodel becoause i used showwindow and every thing you can think of , i create() and then showwindow still didnt work.

  4. #4
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    If you're using MFC then that's the way to go.

    Otherwise you need to use CreateDialog, ShowWindow, and a message loop. Doing this with the API has been answered many times on this forum already.
    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

  5. #5

    Thread Starter
    Member
    Join Date
    May 2001
    Location
    US Of A
    Posts
    41
    thanks man, its just that i didnt see anything about showing a dialog and i searched too

  6. #6

    Thread Starter
    Member
    Join Date
    May 2001
    Location
    US Of A
    Posts
    41
    i tried what you said and it didnt work????

    CPassWord frmPassWord;
    frmPassWord.DoModal();

  7. #7
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    maybe upload the project for review?
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width