I have searched on the forum but am a bit punch drunk by all the information here!
I have the following code:
Docmd.setwarnings False
Docmd.openquery "insertquery"
Docmd.setwarnings true
However, if the query fails (e.g. violations) then as the warnings are 'off' it just gets ignored. If they are 'on' then the user (apart from having to confirm) gets a rather technical error message. What I really would like is to trap any error and deal with it myself.
I have seen references to recordset counting e.g. but surely there must be an easy method?
Thanks one and all for your time.
I have the following code:
Docmd.setwarnings False
Docmd.openquery "insertquery"
Docmd.setwarnings true
However, if the query fails (e.g. violations) then as the warnings are 'off' it just gets ignored. If they are 'on' then the user (apart from having to confirm) gets a rather technical error message. What I really would like is to trap any error and deal with it myself.
I have seen references to recordset counting e.g. but surely there must be an easy method?
Thanks one and all for your time.