I have a very simple macro that runs a query and copy/pastes the result into my form.
The problem I have is: If there is no matching result, I get a couple of errors telling me the copy function cannot be used (as there is no data to copy), the action has failed and the macro grinds to a halt.
(See the attached sample db and .jpg error mssg)
What and where would I enter a line in the macro that upon this event would stop the macro and display a simple mssg box?
I'm not yet familiar enough with vb (starting to learn) so for the time being need a macro to do the job.
Any help would be fantastic.
The problem I have is: If there is no matching result, I get a couple of errors telling me the copy function cannot be used (as there is no data to copy), the action has failed and the macro grinds to a halt.
(See the attached sample db and .jpg error mssg)
What and where would I enter a line in the macro that upon this event would stop the macro and display a simple mssg box?
I'm not yet familiar enough with vb (starting to learn) so for the time being need a macro to do the job.
Any help would be fantastic.