I am getting the error:
Expected: Line Number or Label or Statement or End of Statement
I am using Excel 2007 and here is the code:
This code came from Chapter one of book so I had hoped not to hit a roadblock so soon! Maybe I picked the wrong book! Any help would be appreciated. I have turned off requiring that variables be initiated. I normally wouldn't do that but this is a pretty simple test (at least I thought so). Thanks so much.
Expected: Line Number or Label or Statement or End of Statement
I am using Excel 2007 and here is the code:
Code:
Sub GuessMyName()
Msg = "Is your Name" & Application.UserName & "?"
Ans = MsgBox(Msg, vbYesNo)
If Ans= vbNo Then "Oh Never Mind"
If Ans= vbYes Then "I am pretty Smart!"
End Sub
This code came from Chapter one of book so I had hoped not to hit a roadblock so soon! Maybe I picked the wrong book! Any help would be appreciated. I have turned off requiring that variables be initiated. I normally wouldn't do that but this is a pretty simple test (at least I thought so). Thanks so much.