Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. win32 window + dialog + messagebox

win32 window + dialog + messagebox

Scheduled Pinned Locked Moved C / C++ / MFC
question
10 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    User 3822629
    wrote on last edited by
    #1

    I have winodow and create dialog with createdialog() function. all works fine. But in same time I have to show DialogBox on the dialog. and in this moment DialogBox can't take focus - it has no action on button click on it...can I do something with it?

    M 1 Reply Last reply
    0
    • U User 3822629

      I have winodow and create dialog with createdialog() function. all works fine. But in same time I have to show DialogBox on the dialog. and in this moment DialogBox can't take focus - it has no action on button click on it...can I do something with it?

      M Offline
      M Offline
      Mark Salsbery
      wrote on last edited by
      #2

      Member 3825493 wrote:

      But in same time I have to show DialogBox on the dialog.

      How are you creating this second dialog box? Mark

      Mark Salsbery Microsoft MVP - Visual C++ :java:

      U 2 Replies Last reply
      0
      • M Mark Salsbery

        Member 3825493 wrote:

        But in same time I have to show DialogBox on the dialog.

        How are you creating this second dialog box? Mark

        Mark Salsbery Microsoft MVP - Visual C++ :java:

        U Offline
        U Offline
        User 3822629
        wrote on last edited by
        #3
        1. first Dialog - CreateDialog(...) 2) messageBox - MessageBox(...)
        1 Reply Last reply
        0
        • M Mark Salsbery

          Member 3825493 wrote:

          But in same time I have to show DialogBox on the dialog.

          How are you creating this second dialog box? Mark

          Mark Salsbery Microsoft MVP - Visual C++ :java:

          U Offline
          U Offline
          User 3822629
          wrote on last edited by
          #4

          CreateDialog(hWnd,...) - child of main window MessageBox(m_hWnd,..) - child of the Dialog

          M 1 Reply Last reply
          0
          • U User 3822629

            CreateDialog(hWnd,...) - child of main window MessageBox(m_hWnd,..) - child of the Dialog

            M Offline
            M Offline
            Mark Salsbery
            wrote on last edited by
            #5

            Which dialog can't get user input? Mark

            Mark Salsbery Microsoft MVP - Visual C++ :java:

            U 1 Reply Last reply
            0
            • M Mark Salsbery

              Which dialog can't get user input? Mark

              Mark Salsbery Microsoft MVP - Visual C++ :java:

              U Offline
              U Offline
              User 3822629
              wrote on last edited by
              #6

              MessageBox.

              M 1 Reply Last reply
              0
              • U User 3822629

                MessageBox.

                M Offline
                M Offline
                Mark Salsbery
                wrote on last edited by
                #7

                I can't imagine what's going wrong. What does the MessageBox() call code look like?

                Mark Salsbery Microsoft MVP - Visual C++ :java:

                U 1 Reply Last reply
                0
                • M Mark Salsbery

                  I can't imagine what's going wrong. What does the MessageBox() call code look like?

                  Mark Salsbery Microsoft MVP - Visual C++ :java:

                  U Offline
                  U Offline
                  User 3822629
                  wrote on last edited by
                  #8

                  MessageBox(m_hWnd,text,NULL,NULL);

                  M 1 Reply Last reply
                  0
                  • U User 3822629

                    MessageBox(m_hWnd,text,NULL,NULL);

                    M Offline
                    M Offline
                    Mark Salsbery
                    wrote on last edited by
                    #9

                    Never mind the deleted reply - the default is MB_OK.... It really should work - MessageBox() has been around a long long time.

                    Mark Salsbery Microsoft MVP - Visual C++ :java:

                    U 1 Reply Last reply
                    0
                    • M Mark Salsbery

                      Never mind the deleted reply - the default is MB_OK.... It really should work - MessageBox() has been around a long long time.

                      Mark Salsbery Microsoft MVP - Visual C++ :java:

                      U Offline
                      U Offline
                      User 3822629
                      wrote on last edited by
                      #10

                      I don't now what to say - but even if I make another modless dialog child of my first - it can't take focus...something wrong, but I have no idea what.. :(

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups