February 16, 201510 yr In FM13, if you create a new record, but never commit it, then calling "Revert Record" will delete the record entirely. In FM13 it's also possible to set up a Script trigger for OnRecordCommit to block the auto-commit when the layout has "Save record changes automatically" checked by calling a script that returns a zero result. However, it seems that calling Revert record in such a scenario does NOT delete the record, even if the OnRecordCommit script returned zero. Is there any way around this? I really like the feature where Reverting a record auto-deletes it...
February 16, 201510 yr That behaviour has been around for 10+ years now, it is not new to FM13 and there are no surprises... My guess is that you have something going that actually does commit the record before you call the revert. Can you post a bit more detail about the scripts that you have set up?
February 16, 201510 yr Author Upon further testing, this may be a WebDirect related issue. The Layout Save record changes automatically = true OnRecordCommit calls a script which returns zero The Test: Navigate to this layout call a script that makes a New Record call a script that calls Revert Record Inside FileMaker Pro: When RevertRecord is chosen, the record is deleted. From WebDirect: When RevertRecord is chosen, the record is NOT deleted.
February 16, 201510 yr Author Hmm - the plot thickens: I have a different Table which behaves more like I expect it to: In this table, if a new record is created in WebDirect, it doesn't show up in the FileMaker pro side until it's actually committed, and if you Revert the record before committing, it's deleted. The Table that is not working as I expect uses Custom Record Permissions ; the one that works normally does not. I'll see if I can narrow it down.
Create an account or sign in to comment