Solved

Same Code - Different results

Posted on 2011-03-02
2
242 Views
Last Modified: 2012-05-11
Hi,

..I have tried multiple fixes here but no joy .. 3 hours later..

I have written an audit trail.
There is an additional "memo" field on each record "Auditmemo".
 (Uses OldValue etc).

The audit trail works perfectly on form "AA_ThisWorks". (Note the unique record ID in grey on left of screen).  
The before update event of form is "=audit()".

All good so far!
However, when I try to use this audit trail on another form or table  ... the following happens.

PROBLEM: See AA_ThisFails
If there is more than one change to a single record then ONLY the last change is recorded in the "Auditmemo" field,

WHY ??  This works fine in AA_ThisWorks

(The Audit buttons on the screen may help to understand my problem).
I have hidden some forms/tables from view for simplification


All Help greatly appreciated on this one .... it has been frustrating me for hours.



Database1.zip
0
Comment
Question by:Patrick O'Dea
2 Comments
 
LVL 119

Accepted Solution

by:
Rey Obrero earned 500 total points
ID: 35017190
test this

modified codes in the function audit
Database1.accdb
0
 

Author Closing Comment

by:Patrick O'Dea
ID: 35019375
Perfect - thanks once again
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

It took me quite some time to sort out all the different properties of combo and list boxes available from Visual Basic at run-time. Not that the documentation is lacking: the help pages are quite thorough and well written. The problem was rather wh…
Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now