I have a form with an embedded view, and when a document is opened through this view using double-click, I need to run some javascript to check if the user wishes to save the current document before leaving.
Is there anyway I can relate this code to the view, or is there a web event I can use instead? This code should only ever run if they use this view to exit the document.