Show Save Changes Dialog Before Closing A Document

Does any one know how to Show the Save Changes Dialog Before Closing A Document

Thanks

You have two options:

  • with DOM
    app.activeDocument.close()
  • with batchPlay
psCore.performMenuCommand({
    commandID: 31
  });

Besides, this link mention ▸ close ( saveDialogOptions? : SaveDialogOptions): Promise‹void›

https://www.adobe.io/photoshop/uxp/ps_reference/classes/document/

I couldn’t find any directions in how to use saveDialogOptions

1 Like