Results 1 to 4 of 4

Thread: Modal Form Woes

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jun 2005
    Posts
    30

    Modal Form Woes

    Folks,

    I'm stuck on a problem at the moment where I'm displaying a modal warning screen to users based on data gathered from a database table. A query is kicked off by a timer event firing at regular intervals, and if some data is out of bounds the warning screen is displayed to the user.

    The problem I am having arises from using a pop-up\context menu in the app which is launched when the user right clicks on, for example, a list view or tree view etc.

    However, within my main project everything works ok, but I have other components used in my app which are dll components and when I call the popup menu within these applications and the warning screen appears at the same time, the application appears to freeze. But, clicking on the application in the task bar, seems to return control to the application and the application becomes usable again.

    Also, the forms within the application are MDI child forms(obviously apart from the modal warning form), the Dll forms are not .

    Has anyone encountered a problem like this? Does anyone know how to work around this?

    All advice and help is gratefully received - thanks in advance!

    Morrislgn

  2. #2
    VB6, XHTML & CSS hobbyist Merri's Avatar
    Join Date
    Oct 2002
    Location
    Finland
    Posts
    6,654

    Re: Modal Form Woes

    Instead of displaying a modal form you could just display it on top of the main form, ie.
    Code:
    PopupWarning.Show , MainForm
    This lets user continue working in the other forms while the warning message is still displayed on top of everything, so you can be sure the user sees it. Atleast this wouldn't halt any code execution and thus it shouldn't interrupt handling of window messages (that probably don't get to their final destination due to the modality of the warning form).

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Jun 2005
    Posts
    30

    Re: Modal Form Woes

    Thanks dude!

    That seems to do the job well, thanks very much for your help!!

  4. #4
    Former Admin/Moderator MartinLiss's Avatar
    Join Date
    Sep 1999
    Location
    San Jose, CA
    Posts
    33,431

    Re: Modal Form Woes

    Now that we've helped you, you can help us by pulling down the Thread Tools menu and clicking the Mark Thread Resolved button which will let everyone know that you have your answer. Also if someone has been particularly helpful, or even particularly unhelpful, you have the ability to affect a their forum "reputation" by rating their post.

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