Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Enable or Disable Button

Status
Not open for further replies.

NaWin55

Mechanical
Mar 21, 2020
97
0
0
IN
HI
i have to create this user form based on some conditions
i want the create button to enabled only if the
user Select Surface and select line and UDU or LDU is chosen and checkbox is checked

here is the userform
userform_biugwk.png


the CREATE button must be frozen until user selects and checks necessary data

i tried with some IF ELSE conditions like
if checkbox.enabled = true then
create.enabled = true​
else
create.enabled = false​
End if

but didnt work
how to write script for the
VBScript
 
Replies continue below

Recommended for you

Hej

Put it under CheckBox1

Code:
Private Sub CheckBox1_Click()
    If CheckBox1.Value = True Then
        CommandButton1.Enabled = False
    ElseIf CheckBox1.Value = False Then
        CommandButton1.Enabled = True
    End If
End Sub

Regards
Santa
 
Status
Not open for further replies.
Back
Top