• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Photoshop document save on Mac throws Error : The document has not yet been saved.

Community Beginner ,
Nov 04, 2014 Nov 04, 2014

Copy link to clipboard

Copied

Hi,

I have a very simple script that would save the changes in a PS document. The script is as practically as mentioned below :

if(app && app.activeDocument) {

     app.activeDocument.save();

}

This was working fine. But all of a sudden, I started getting the error - Error : The document has not yet been saved. The file on which I am trying to run the script is located in /Users/qa/Documents/sample.psd. The file is already saved on disk and am running the script after making some changes to the file. I am using the Photoshop CC 2014 and Mac OS X version 10.10. This is a show-stopper for me and I need to resolve this urgently. Looking forward to any help.

Thanks in advance.

TOPICS
Actions and scripting

Views

644

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Community Expert ,
Nov 15, 2014 Nov 15, 2014

Copy link to clipboard

Copied

Could it be a permissions issue?

Have you tried using a try-clause and in case of an error using saveAs instead?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Nov 15, 2014 Nov 15, 2014

Copy link to clipboard

Copied

Sounds like a general "something went wrong and dont know what to do"-error, which can be difficult to solve. Try to narrow it down in exactly what conditions it happens:

- Comment that line, run script and save from PS menu (sometimes PS can give more informative errors)

- Try rebooting computer and running freshly started Photoshop

- Try copying file in Finder and running it for that

- Try running from different folder like Desktop

- Try CC 2012

- Try commenting out script operations that change the doc one at the time

Idea is to see what things could make the issue go away

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Nov 17, 2014 Nov 17, 2014

Copy link to clipboard

Copied

LATEST

Thanks for your inputs. I did try to use saveAs instead. Also tried different options - restarting PS, rebooting machine etc, none of which worked. Finally got the save operation to work by using the Action Manager code that gets generated using the ScriptListener. That piece of code seemed to work fine. Still don't have any idea why the .save() method was not working. Will look into it again when I get some time.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines