Hi,
Working on a project that requires an audit trail and we've created a class that works fine when called from Events|Server-Side | afterDialogValidate
The class accepts a parameter that we want to use to indicate whether the action was Insert|Update|Delete.
It works fine, except that we haven't figured out a way within the afterDialogValidate Event to determine if the Action was Insert, Update or Delete.
So searching through the Video Help, I found a video on CRUD (CReate|Update\Delete) and noticed that if you're using the ExecuteServiceSideAction JavaScript that there are placeholders for specific functions to be called for Before/After all of the three main Actions.
For each afterXFunction, I copied the corresponding template code as recommended by the video and pasted it into the UX's Code|XBasic Function and then pasted the call to the AuditTrail function that resides in the Control Panel's Code area that worked in the afterDialogValidate in the three new functions.
Because I wanted to track changes at a field level, originally I did a FOR Each ItemName in e.dirtyColumns loop and that worked fine.
But now calling it from within the ExecuteServiceSideAction process I get an error that the e.dirtyColumns property doesn't exist.
Does anyone have any idea why even though the e pointer's dirtyColumn property is available to the Class code when passed from the afterDialogValidate, it's not available when called from within the ExecuteServiceSideAction|AfterXFunction call?
Thanks
Kevin
Working on a project that requires an audit trail and we've created a class that works fine when called from Events|Server-Side | afterDialogValidate
The class accepts a parameter that we want to use to indicate whether the action was Insert|Update|Delete.
It works fine, except that we haven't figured out a way within the afterDialogValidate Event to determine if the Action was Insert, Update or Delete.
So searching through the Video Help, I found a video on CRUD (CReate|Update\Delete) and noticed that if you're using the ExecuteServiceSideAction JavaScript that there are placeholders for specific functions to be called for Before/After all of the three main Actions.
For each afterXFunction, I copied the corresponding template code as recommended by the video and pasted it into the UX's Code|XBasic Function and then pasted the call to the AuditTrail function that resides in the Control Panel's Code area that worked in the afterDialogValidate in the three new functions.
Because I wanted to track changes at a field level, originally I did a FOR Each ItemName in e.dirtyColumns loop and that worked fine.
But now calling it from within the ExecuteServiceSideAction process I get an error that the e.dirtyColumns property doesn't exist.
Does anyone have any idea why even though the e pointer's dirtyColumn property is available to the Class code when passed from the afterDialogValidate, it's not available when called from within the ExecuteServiceSideAction|AfterXFunction call?
Thanks
Kevin
Comment