View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Mike H. Mike H. is offline
external usenet poster
 
Posts: 471
Default Toggle Event - 2 Commands on 1 Button

I think this is what you wish to do (This is the code behind a button):

Private Sub CommandButton2_Click()
If CommandButton2.Caption = "Second Step" Then
CommandButton2.Caption = "First Step"
Call SecondStep
ElseIf CommandButton2.Caption = "First Step" Then
CommandButton2.Caption = "Second Step"
Call FirstStep
End If
End Sub