Showing posts with label ShowDialog. Show all posts
Showing posts with label ShowDialog. Show all posts

Wednesday, November 3, 2010

Multiple Forms

If your application calls for multiple forms:

1. Create the required forms via the 'Add New Item' option.
2. Design the form as required.
3. To launch an instance of one form from another:

Dim FormInstanceName as New FormClassName
FormInstanceName.ShowDialog()

- Shows the form as a modal window.

Dim FormInstanceName as New FormClassName
FormInstanceName.Show()

- Shows the form as a normal window.

Form.ShowDialog Method

"Shows the form as a modal dialog box."

From MSDN "Form.ShowDialog Method (System.Windows.Forms)" ( http://bit.ly/c6lYQ1 )