Copy link to clipboard
Copied
Of course I can do Control-Alt-W (WINDOWS) to close all but the pop-up Save? dialog interrupts my rhythm and I need a script that allows me to Close All -> No Save. I have tried an Action where I record the "No" (with option) to attempt to get it to say No on each one, but it does not record that part, only the Close All.
#target illustrator
function CloseAllWithoutSaving(){
for(var i=app.documents.length-1; i>-1; i--){
app.documents[i].close(SaveOptions.DONOTSAVECHANGES);
};
};
CloseAllWithoutSaving();
Copy link to clipboard
Copied
#target illustrator
function CloseAllWithoutSaving(){
for(var i=app.documents.length-1; i>-1; i--){
app.documents[i].close(SaveOptions.DONOTSAVECHANGES);
};
};
CloseAllWithoutSaving();
Copy link to clipboard
Copied
THANK YOU !!!
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Shouldn't:
app.documents.close(SaveOptions.DONOTSAVECHANGES);
be:
app.activeDocument.close(SaveOptions.DONOTSAVECHANGES);
Copy link to clipboard
Copied
It's cause a forum migration messed up the code snippets on here, the code should be (and I fix these as users point these out, there's 1000s) :
app.documents[i].close(SaveOptions.DONOTSAVECHANGES);