Jump to content
Xtreme .Net Talk

Passing value to another form


Recommended Posts

Posted

I am very new at the VB .Net...Came from programming in Access 97.

 

I have a MainMenu form with button captions that will change, depending on data in a table. What I want to do is when a button is pressed on the main menu, I want to pass the caption of the button to another form, which names a certain label box.

 

LOL...I just found out how to open another form from a form (another post I read), but would like to somehow transfer data to form 2.

 

Any suggestions?

 

Nick

  • *Gurus*
Posted

There are a *lot* of threads in this forum answering exactly that question. At least 1 in 10, probably more :)

 

Try to remember that forms are just classes, and to change something on a class you need a reference to it. Just using the name of the form won't work because you need an instance.

MVP, Visual Developer - .NET

 

Now you see why evil will always triumph - because good is dumb.

 

My free .NET Windows Forms Controls and Articles

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...