Question of Windows Forms

  • Thread starter Thread starter Richard
  • Start date Start date
R

Richard

Hi,

I have two Windows forms that are both open. What I want is when I click a
button on the first form it to copy the text from a textbox and put the text
into a textbox on the second form. Can anyone tell me the best way to
reference the second form with is already open from the first form?

Thanks
Richard
 
Well the second form could have a protected property....

so that it's set actually sets the TextBox or whatever

if so in form 1
dim f2 as new form2 'make this module level on form 1 if need be.

f2.MyTextProperty="Some Text"
f2.show

so if already showing

on form1 in
button1_click
f2.MyTextProperty="Some more text"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top