This topic is locked

Compare-Confirm on BeforeEdit

2/28/2007 2:31:38 PM
ASPRunnerPro General questions
V
VORONOY author

Hi,
May be anyone already did it:
I have 2 users updating same table with same data twice. It is error sensitive and needs to be confirmed that is no difference exist in entered data. (i.e. mistypes etc.)
What I need, is to have a First user to enter data into table and Second user(Manager) to enter same data and get a comparison page with mismatched data, populated next to the inserted field, so Second User can make decision and approve update or cancel it. If no mismatched data found - just update record.
Simple table: Table_1
ID- Primary

DATA1- Data that needs to be compared

DATA2- Data that needs to be compared
Thanks!

Sergey Kornilov admin 3/2/2007

I would create a BeforeEdit event that pulls existing record from the database and compares old value with new one.

See sample actions "Send an email with old data record" and "Send an email with new data record" to get an idea how to access new and old records.
Depending on comparison result you can approve or disapprove record edit and display an error message.