[VBA]' Determine if name has been entered
If txtName.Text = ""Then
MsgBox("You must enter your name.", , "Input Error")
EndIf
' Determine if Hours entered are between 5 and 60
If txtHoursWorked.Text < 5 Or txtHoursWorked.Text > 60 Then
HoursResponse = MsgBox("Hours worked must be at least 5 and no more than 60.", , "Input Error")
txtHoursWorked.Text =
""
EndIf
' determine if payrate entered is within 8.00 and 40.00
If txtPayPerHour.Text < 8.0 Or txtPayPerHour.Text > 40.0 Then
HourlyPayResponse = MsgBox("Pay rate must be between 8.00 amd 40.00.", , "Input Error")
txtPayPerHour.Text =
""
EndIf
[/VBA]