0

I wish to if someone types something in a textbox that it shows up in a label..but on another form...so say in the textbox i type in "Sharpy" then "Sharpy" shows up on another form.

4
Contributors
6
Replies
10
Views
12 Years
Discussion Span
Last Post by jwshepherd
0

thought this could help;
Private Sub Command1_Click()
Form2.Show
Form2.Text1.Text = Form1.Text1.Text
End Sub
Form1 has 2 controls, text1 and command1

0

doesn't help me sorry, I want it so when you type in a word in the Text Box and click on a button then it will show up in the next form

0

Change this line:
Form2.Text1.Text = Form1.Text1.Text

to this:
Form2.Label1.Caption = Text1.Text

Or did you not want to use a command button?
You could try Text1_Change, instead of Command1_Click.

If you don't want Form2 to show at this point, then use "Load Form2" earlier, then you can Show or Hide it as you need to.

hope that helps, if not give us a little more explanation of what you want to do.

0

try using the text1.change() event That way it is automatically change whenever you type something

public Sub text1_change()
     form1.label1.caption = trim(text1.text)
end sub
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.