Announcement

Collapse
No announcement yet.

Modeless dialog

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Modeless dialog

    Until now I allways used modal DDT dialogs. I now need to use some modeless
    dialogs. If I assign a callback function to the dialog, do I still need to use DOEVENTS?
    (It seems to work fine without ....) If so, what is the best place to put DOEVENTS
    when using multiple modeless dialogs?.....

    ------------------
    Peter.
    mailto[email protected][email protected]</A>
    Regards,
    Peter

    "Simplicity is a prerequisite for reliability"

  • #2
    There has to be a (thread-specific) message pump in the mix somewhere.

    For example, if you have a MODAL dialog running (in the same thread) for the life of the (child?) modeless dialog, then the modal dialog will handle the pump action for you. For example, a FIND modeless dialog per the example in ADDRESS.BAS.

    However, if you _only_ have modeless dialog(s) running then you must have a message pump running.

    The construction and operation of a message pump for a modeless dialog can be found in the DDT section in the help file.

    If you could describe the GUI aspects of your application in a little more detail, then we should be able to advise you with specifics.

    PS: Do you have a Windows programming "bible", such as Petzold? These issues are discussed in depth in most GUI programming books.

    ------------------
    Lance
    PowerBASIC Support
    mailto:[email protected][email protected]</A>
    Lance
    mailto:[email protected]

    Comment


    • #3
      Thanks Lance,

      I always have a main modal dialog running, so doevents should not be needed...
      The helpfile does not really explain that doevents is only needed when only modeless
      dialogs are present. (Also it does not explain where to put doevents if you have multiple
      modeless dialogs....)
      I have the Petzold bible

      ------------------
      Peter.
      mailto[email protected][email protected]</A>
      Regards,
      Peter

      "Simplicity is a prerequisite for reliability"

      Comment

      Working...
      X