How Does the Audit Trail Work

mkaeser20

New member
Local time
Today, 05:04
Joined
Sep 2, 2015
Messages
5
Hello All,

I have seen several examples on audit trails where the sub or function is called by the form_beforeupdate sub. However, in the DB I am working with, none of the forms have that code. Yet, the audit trail is working. When I put stops on the sub and function and do a task such as entering a new customer, it never calls on either the sub or function yet a record is entered in the audit table to show I entered a new customer.

The only other thing I can think of is that parts of the code may be hidden, if that is even possible? Otherwise, I have no idea how information is being entered in the audit trail table when there is no form calling on this sub or function. Any ideas?
 
I haven't done it that way, but I believe it can also be done with a data macro. You might look for one of those.
 
THANK YOU ONE MILLION TIMES!!!
That was exactly it!

NEXT QUESTION:
Is there a benefit to doing things this way?
 
Happy to help! I haven't used data macros, but I guess one advantage to using one is that there's probably no way around it. Sometimes users find ways around code behind a form (usually accidentally, not maliciously). That said, the update events that audit code would fire from are pretty reliable, so not likely to be bypassed. I guess my final answer is "use the method you're comfortable with".
 
Interesting. Do data macros work on linked tables?
 
Happy to help! I haven't used data macros, but I guess one advantage to using one is that there's probably no way around it. Sometimes users find ways around code behind a form (usually accidentally, not maliciously). That said, the update events that audit code would fire from are pretty reliable, so not likely to be bypassed. I guess my final answer is "use the method you're comfortable with".

There doesn't seem to be a way to lock down the data macros like vba. All you would have to do is go into the back end to start mucking things up, wouldn't the sub or function be better controlled?
 
There doesn't seem to be a way to lock down the data macros like vba. All you would have to do is go into the back end to start mucking things up, wouldn't the sub or function be better controlled?

That sounds logical. Not having used them, I'm only speculating. Certainly VBA code could be hidden by distributing an mde/accde.
 
Last edited:
google of course
smack-self-in-the-head.gif


Thanks for the answer Paul.
 

Users who are viewing this thread

Back
Top Bottom