-
Ok heres my problem... I have 2 forms.
A login form with the (txtUserName and txtPassword)
and a Main form. (frmLogin and Form1)
On Form1 I have label1 at the top...how do I set it up so that whatever is written in txtUserName on the frmLogin, appears in Label1 on Form1?
Thanks
-
"how do I set it up so that whatever is written in txtUserName on the frmLogin, appears in Label1 on Form1?"
(in the form with Label1)
Label1 = Form1.txtUserName
-
Just try:
Form1.Label1=frmLogin.txtUserName
Lior, An Israeli Programmer.
-
Label1 = frmLogin.txtUserName
i had it backwards
-
Ok I figured it out. Thanx
I had to set it up so when Ok was pressed it made the label1.Caption set to the txtUserName. Thanks again! :)
-
You can also reference objects on other forms by using
'Change a property
FrmOther!MainWindowText.Text = "Blah"
'Execute a function
FrmOther!OpenCmd_Click