Hi everybody!
I am currently working on a form, which performs some check during the OnValidate event. If certain criteria are met, it uses the sc_error_message macro to display an error message and prevent the form from being saved. So far, so good.
The problem comes after being shown the error message. If the user selects to exit the form at that point, the message concerning unsaved changes does not show up and all the (still unsaved !!) data in the form is lost. This loss of data is quite unfortunate.
Is there an elegant way to solve this?
As an alternative,I have tried to use the sc_alert macro instead. This way, the data is always saved. Unfortunately, the alert message only shows up at the fist attempt of saving and not for any subsequent ones, even though the criteria for it showing up are still met.