Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

open up another form 1

Status
Not open for further replies.

magmo

Programmer
May 26, 2004
291
0
0
SE
Hi


I have a a windows form with a mainmenu that displays "about". I thought that I would pop up another form that displays some information about the program. Is the right way to add another form to the project, and if so, how do I call that form to pop up in front of the main form and display the information?


Regards
 
You do need to add another form to the project and you can display it as follows:

Assuming the form is called frmNewForm

Code:
dim fmNewForm as New frmNewForm
fmNewForm.Show()

or

Code:
dim fmNewForm as New frmNewForm
fmNewForm.ShowDialog()

show will allow users to access other forms while that form is open and showdialog will not.
 
Sorry to open an old thread, but I tried that and I get "Type 'Form1' is not defined.(BC30002)
 
Never mind, got it...in Form1.vb, there was a typo in the namespace lol...(damn all these problems that I figure out myself and then I end up hitting myself becuase of it :p)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top