Euro5
asked on
VBA resume error
I have the following code, which has user enter employee number if blank, or just run the program.
It works if there is no employee number - the box pops up as required.
But if the employee number is there, it errors on "Resume"
Can anyone help?
It works if there is no employee number - the box pops up as required.
But if the employee number is there, it errors on "Resume"
Can anyone help?
If Sheets("Queries").Range("F24").Value = True And Sheets("Selection").Range("C1").Value = "" Then Sheets("Selection").Range("C1").Value = InputBox("Must enter your employee number") Else Resume
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Actually, could probably do it shorter:
If Sheets("Queries").Range("F24").Value = True And Sheets("Selection").Range("C1").Value = "" Then
Sheets("Selection").Range("C1").Value = InputBox("Must enter your employee number")
End If
Variable1 = Sheets("Queries").Range("F24").Value
Variable2 = Sheets("Selection").Range("C1").Value
ASKER