Link to home
Start Free TrialLog in
Avatar of ittechie100
ittechie100

asked on

Error Code assistance

VS6 SP5,

Have a form that employees fill out and then click submit button to email the contents of their
request to a manager, problem is if they forget to select who there manager is from combo2.text
it errors out and they loose everything else in the form they have already entered...I need error
control that will stop in the event of an error and allow the user time to select a manager
and continue with the submit button....Please help..


On Error GoTo err5
Select Case Combo2.Text
          Case Is = "user1", "user2", "user3", "user4"
          Case Else
          MsgBox "You are required to select a manager to send the request to!"
End Select
err5:
Err.Clear

The Err.Clear above still alows the rest of my code to run...

More code that send email confirmation....
Avatar of leclairm
leclairm

Have you tried putting an "exit sub" in the error handler??
ASKER CERTIFIED SOLUTION
Avatar of leclairm
leclairm

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ittechie100

ASKER

Thank you..Sorry for something so small, however I've never taken any programming classes, learning as I go...

Thanks...
Thanks for the points and good luck with your learning process.