By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,694 Members | 1,845 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,694 IT Pros & Developers. It's quick & easy.

Load/Unload forms

P: n/a
I am used to VB6 where frmMain.unload, frmNew.load worked.

What replaced this in vb.net?
Nov 20 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
"Brett Baisley" <bb******@nbnet.nb.ca.REMOVE> schrieb
I am used to VB6 where frmMain.unload, frmNew.load worked.
You mean Load frmMain and Unload frmMain? ;-)
What replaced this in vb.net?


To create a Form instance use
Dim frmMain As New MyMainForm

To show it call
frmMain.Show
The first time before the Form is shown, it's Load event is raised.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #2

P: n/a
* "Brett Baisley" <bb******@nbnet.nb.ca.REMOVE> scripsit:
I am used to VB6 where frmMain.unload, frmNew.load worked.

What replaced this in vb.net?


\\\
Dim f As New Form1()
f.Show()
///

.... later:

\\\
f.Close()
///

--
Herfried K. Wagner
MVP VB Classic, VB.NET
<http://www.mvps.org/dotnet>

<http://www.plig.net/nnq/nquote.html>
Nov 20 '05 #3

P: n/a
In dot Net,form is an object.
It still have Load function,you can place codes in
there ,but it does not have an event called Unload.Instead
of that ,dot Net have an event which is called Disposed.
Nov 20 '05 #4

P: n/a
Awesome, Thanks guys!

"Brett Baisley" <bb******@nbnet.nb.ca.REMOVE> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
I am used to VB6 where frmMain.unload, frmNew.load worked.

What replaced this in vb.net?

Nov 20 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.