P
Pawan
Hi..
I have created a macro. One variable is defined there as:
dim var1_d as integer
var1_d=200
Then on the userform, I have a textbox (var1) and a checkbox (cvar1) next to
it.
Requirement:
When I click checkbox (cvar1), value of var1_d from macro should get copied
to textbox (var1).
My code is:
Private Sub cvar1_Click()
If cvar1 = True Then
UserForm1.var1.Value = var1_d
End If
End Sub
However it is not working. What is wrong in my code?
Thank you
Pawan
I have created a macro. One variable is defined there as:
dim var1_d as integer
var1_d=200
Then on the userform, I have a textbox (var1) and a checkbox (cvar1) next to
it.
Requirement:
When I click checkbox (cvar1), value of var1_d from macro should get copied
to textbox (var1).
My code is:
Private Sub cvar1_Click()
If cvar1 = True Then
UserForm1.var1.Value = var1_d
End If
End Sub
However it is not working. What is wrong in my code?
Thank you
Pawan