Activating/De-activating buttons
How do I find the name of the button? Thanks,
"abcd" wrote:
if the button objet vba's name is commandbutton1 on the Sheet1 object then:
Sheet1.CommandButton1.Enabled = false ' or true
the change event of this sheet may be used to detect a change on that sheet
example:
Private Sub Worksheet_Change(ByVal Target As Range)
If Not (Intersect(Target, Range("A1")) Is Nothing) Then
CommandButton1.Enabled = Not CommandButton1.Enabled
End If
End Sub
|