CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2003
    Posts
    2,185

    Dialog return codes

    Hi all,

    I want to create a special confirmation dialog (like the AfxMessageBox() == IDYES).

    I have a dialog created. How can I decide which code is returned from DoModal? If that is not possible, I want to create a new function int AskConfirmation().

    But then I need to set the return value as soon as the dialog closes.

    Any idea how to do this?

    Thanks!

  2. #2
    Join Date
    May 2000
    Location
    Scotland, Livingston.
    Posts
    728

    Re: Dialog return codes

    Use the EndDialog method to return a value from DoModal.
    Dave Mclelland.

  3. #3
    Join Date
    Nov 2003
    Posts
    2,185

    Re: Dialog return codes

    Works perfect!

    Thanks!

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

Featured