How do I create a modal dialog box?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am using vb. My second form is displayed with

dim frmAbout as new Form2
frmAbout.show()

The problem is that frmAbout is also displayed in the
iTask list, and the form is not modal, i.e. I can bring
up the main form while form2 is still showing. I need
a modal form, any ideas?
 
guy said:
I am using vb. My second form is displayed with

dim frmAbout as new Form2
frmAbout.show()

The problem is that frmAbout is also displayed in the
iTask list, and the form is not modal, i.e. I can bring
up the main form while form2 is still showing. I need
a modal form, any ideas?

dim frmAbout as new Form2
frmAbout.ShowDialog() //the form will be modal ;)
 
Thanks it's working, I think I would have been really
stuck without you people, thanks for your great help.
 
it will appear modal.....

if you made this form to be not full screen, and you call it with
showdialog, then click on the form beneath it, it WILL display that other
form and hide this 'modal' dialog box in the background. Its not truly
modal this way, in my eyes anyway.
 
Back
Top