What is wrong with this visual basic formula

New Contributor

I am trying to show a different form based on the content of a cell. The cell I am referencing will have either a 1 or 0 in it. 


Worksheets("Sheet3").Range("A11").Formula = "=if("a11"=>"1" Then Else frmfunny.Show)"

4 Replies
best response confirmed by Hans Vogelaar (MVP)

@Bob_Hayes Try:


If Worksheets("Sheet3").Range("A11").Value >= 1 Then frmselect.Show Else frmfunny.Show



I like that but I still get a Subscript out of range error?
Is your worksheet is actually named Sheet3?
Sheet3 is named Start. I changed the name and it worked, thank you.