View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Shoney Shoney is offline
external usenet poster
 
Posts: 17
Default disable multiple toggle buttons

Hi,

I'm trying to disable multiple toggle buttons (ToggleButton1 and
ToggleButton2). I am currently using this code for ToggleButton1:

Private Sub Worksheet_Change(ByVal Target As Range)

Dim Temp As Double
Temp = Range("J4") / Range("H4")
If Temp < 0.5 Then
ToggleButton1.Enabled = True
Else: ToggleButton1.Enabled = False
End If
End Sub

....and it works great.

But now, I have another toggle button on the same sheet and I want it to be
enabled only if cell L4 is greater than or equal to 300. I've searched the
site and tried everything I can think of, to no avail.

If it is possible to enable/disable multiple toggle buttons on the same
worksheet, please let me know how I should adjust my code or what additional
code I need to use to make it work.

Thank you.