CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2012

    How to make 2 simultaneously executing Dialogs in VC++ Win32??

    First I'll explain what exactly I want to do here. I have a dialog box in which I am showing a frame. Using menu from this dialog, I open another Dialog box which shows me macrogrid block information from the first dialog. So to show 2nd dialog box I am using function : DialogBox(hInst, MAKEINTRESOURCE(IDD_DIALOG1), NULL, DialogProc);
    But this transfers the execution of the program to the new dialog box and I can't process further messages in the 1st dialog unless I close the new dialog box.

    Can someone please tell me a way to solve this problem??? Is it the same thing as modal vs modeless dialog-boxes??


  2. #2
    Join Date
    Apr 2012

    Re: How to make 2 simultaneously executing Dialogs in VC++ Win32??

    By MSDN
    DialogBox function creates a modal dialog box from a dialog box template resource. DialogBox does not return control until the specified callback function terminates the modal dialog box by calling the EndDialog function.
    Processing data passed from another resource isn't necessarily related to modal or modeless, you can provide a background worker thread to do the task pretty easily. If the displayed dialog needs interactive modes with mouse or direct keyboard control, then you may need to eliminate the modal-ness.

  3. #3
    Join Date
    Jun 2012

    Re: How to make 2 simultaneously executing Dialogs in VC++ Win32??

    Thanks for your reply. Can you please tell me how exactly does BackgroundWorker thread works? I tried to look for it on MSDN and other resources, but couldn't really understand it well. Or if you have a good resource using which I can understand it and implement it for my case please let me know. That would really help. Thanks a lot once again.

Tags for this Thread

Posting Permissions

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

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

On-Demand Webinars (sponsored)

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.