Hi all,
Apologies if this topic has come up before…
As part of a work project, I need to save transparent PNGs of our products in a new range of colours.
Currently, my action process is as follows:
SAVE (original product colour)
Change product colour to blue
SAVE
Change product colour to red
SAVE
etc.
At present, the save command overwrites each previous file. What I’d really like is a script which will save each item with the following suffix: FILENAME_WHITE, FILENAME_BLUE, etc.
Any help would be massively appreciated!
Saving PNGs with suffixes as part of an action
Re: Saving PNGs with suffixes as part of an action
Bonjour
Something like this :
Something like this :
Code: Select all
//NomImageCouleur.jsx
var docRef = app.activeDocument
var docName = docRef.name;
var COUL = new Array( "BLUE", "RED", "WHITE" ); // ajouter des couleurs ....
//alert(docName);
newName = docName.slice(0,-4);
//alert(newName);
for (i = 0; i<COUL.length; i++ )
{
newNameFinal = newName + "_" + COUL[i];
//alert(newNameFinal);
FileName = newNameFinal;
//FUNCTION savePNG( Filename ) = lancer les sauvegardes avec les nouveaux noms
}