TomJamieson
Registered User.
- Local time
- Today, 21:01
- Joined
- Jun 8, 2006
- Messages
- 50
I have a piece of code that opens up a form and displays the record by an ID the user specifies in a text box. If the box is empty and they press the button, it errors and opens the VBA code. Obviously this is not something I want the user to see.
Firstly I tried an if statement so if the text box was empty, it would give msgbox telling the user to fill in the ID text box, but it still runs the rest of the code, even though I use the else statement. I wondered if there was a way to stop this, or if not, just a way to specify on erroring, to give a custom msgbox not go straight to the debugger?
Firstly I tried an if statement so if the text box was empty, it would give msgbox telling the user to fill in the ID text box, but it still runs the rest of the code, even though I use the else statement. I wondered if there was a way to stop this, or if not, just a way to specify on erroring, to give a custom msgbox not go straight to the debugger?