Skip navigation
Livecycle form
Currently Being Moderated

Avoid "Do you want to save changes to <filename> before closing?"

Jun 13, 2012 3:49 AM

Hi,

 

When I open a reader enabled form and close it without doing anything it prompts "Do you want save changes to <filename> before closing?". How to get rid of this? I tried the below code in the layout ready event of a button but still no effect.

 

event.target.dirty=false;

event.target.requiresFullSave=false;

 

 

Any solution is greatly appreciated. Many thanks in advance.

 
Replies
  • Currently Being Moderated
    Jun 13, 2012 4:18 AM   in reply to Livecycle form

    You can create a close Button with this script in its click event.

     

    event.target.closeDoc(true);

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 14, 2012 1:09 AM   in reply to Livecycle form

    The script you already use

         event.target.dirty = false;

     

    is the only way to avoid that.

    If it doesn't work, then because of any other script, that is executed also in the layoutReady event that causes to change the dirty flag back to true.

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 29, 2012 1:36 AM   in reply to Livecycle form

    What's the other script you use and why?

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 29, 2012 3:40 AM   in reply to Livecycle form

    The show/hide script in the layoutReady event is the problem as it dirties the form permanently.

    You should use another event to control the visiblity, like the change event.

     
    |
    Mark as:
  • Currently Being Moderated
    Jul 3, 2012 2:52 AM   in reply to Livecycle form

    Can you share your form please?

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points