I am using Apex 19.1 and have some problems with warn On Unsaved Changes and modal dialogs: it doesn't seem to work at all.
- On a form page, create a button with action Redirect to page in this application. Choose a modal page and set Warn on Unsaved Changes to Page Default (of course, set this property first on page level).
- Run the page, modify something and click the button. There is no warning.
Change the redirect to a non modal page, and now you will get the "Leave site?" message.
The same problem exists for Close Dialog on the modal page.
- Create a button on the modal page.
- Create a DA for this button of type Close Dialog.
- Run the modal page, change something in a form item, and click the button. There is no warning
- Change the button action to a redirect to the calling page.
- Run it again, change something, and click the button. Now you do get the "Leave site?" message.
Is this intended behaviour or not?
If it is, is there a general workaround? Right now, I am disabling certain buttons as soon as the user starts typing. This will force the user to click the Save button before doing anything else. But this is a lot of manual work.