K
krayten
Please help me to work this out!!
The code below is from my UserForm3 which is a simple form with
three textboxes, from which I need to gather some variables _for later
use_.
I am testing with gathering the variables ( hostname, UserID and pass )
then
I want to show message boxes showing their values ( on submit - at the
top ).
I'm a real newbie to xlvba and would really appreciate some help
regarding how to
get the values of a textbox "out" of it's own textbox change sub.
Thanks in advance!
Stuart
' On Submit
Sub CommandButton2_Click()
MsgBox hostname
MsgBox UserID
MsgBox pass
End Sub
' Cancel and clear
Sub CommandButton3_Click()
Unload UserForm3
UserForm3.Hide
End Sub
' Enter the hostname
Sub TextBox1_Change()
Dim hostname As String
hostname = TextBox1.Text
End Sub
' Enter the user id
Sub TextBox2_Change()
Dim UserID As String
UserID = TextBox2.Text
End Sub
' Enter the password
Sub TextBox3_Change()
Dim pass As String
pass = TextBox3.Text
End Sub
Private Sub UserForm_Click()
End Sub
The code below is from my UserForm3 which is a simple form with
three textboxes, from which I need to gather some variables _for later
use_.
I am testing with gathering the variables ( hostname, UserID and pass )
then
I want to show message boxes showing their values ( on submit - at the
top ).
I'm a real newbie to xlvba and would really appreciate some help
regarding how to
get the values of a textbox "out" of it's own textbox change sub.
Thanks in advance!
Stuart
' On Submit
Sub CommandButton2_Click()
MsgBox hostname
MsgBox UserID
MsgBox pass
End Sub
' Cancel and clear
Sub CommandButton3_Click()
Unload UserForm3
UserForm3.Hide
End Sub
' Enter the hostname
Sub TextBox1_Change()
Dim hostname As String
hostname = TextBox1.Text
End Sub
' Enter the user id
Sub TextBox2_Change()
Dim UserID As String
UserID = TextBox2.Text
End Sub
' Enter the password
Sub TextBox3_Change()
Dim pass As String
pass = TextBox3.Text
End Sub
Private Sub UserForm_Click()
End Sub