Copy link to clipboard
Copied
Hi!
When running this script from an unsaved document it works perfectly, however it includes the .psd extension when run for a previously saved doc ie. docname.psd.txt which has no data.
I'm not a coder in any shape, form or fashion but it seems intuitive that having the script remove .psd before saving will fix this. I just don't know exactly what to put where in the code to do this.
I attached the script as a text document for you to have a look.
Thank you so much for your help! 🙂
~Karen
Update: Turns out it had nothing to do with the file name. All groupings have to be removed in order for the data to export.
I'll just leave it at that for now & take these extra steps.
Copy link to clipboard
Copied
Untested, but try changing the following...
From:
var docName = decodeURI(activeDocument.name);
To:
var docName = decodeURI(activeDocument.name.replace(/\.[^\.]+$/, ''));
Copy link to clipboard
Copied
Output is still blank.
Copy link to clipboard
Copied
Update: Turns out it had nothing to do with the file name. All groupings have to be removed in order for the data to export.
I'll just leave it at that for now & take these extra steps.