Copy link to clipboard
Copied
I work for a small sign company and we print from photoshop every day. We currently have actions that save our print settings for each file. The problem is that we have 1000's of signs with many different sizes. So we have to save print settings for each file using our actions. I am wondering if there is a way to run actions based on the size or the image. For instance if we open a 12" x 12" image, photoshop would know to run our 12" x 12" Action and apply our print settings for paper size and all of that. Does anyone know if there is a way to do this? We would love to get some more automation into our process.
Thanks to anyone that can help.
Copy link to clipboard
Copied
Yes, that's doable, but how many different print settings or sign sized do you have?
Copy link to clipboard
Copied
Quite a few. We do a lot of laser cut work and sublimation so the sizes vary. Even in our standard sizes have about 20. I am sure this makes it harder haha.
Copy link to clipboard
Copied
Not really know how things are set up, here's a simple script that will take the size of a file in inches, and then run an action. Trouble is that you would have to populate the switch statement with each file size and each corresponding action that you want to run.
#target photoshop
app.preferences.rulerUnits = Units.INCHES;
var doc = activeDocument
var docSize = parseInt(doc.width) +'X' + parseInt(doc.height);
switch (docSize){
case '12X12':
runAction ('YourActionSetHere', '12" X 12"');//add appropiate name for the action and action set you're using
break;
case '14X14':
runAction ('YourActionSetHere', '14" X 14"');
break;
}
function runAction(actionSet, actionName){
var idPly = charIDToTypeID( "Ply " );
var desc4 = new ActionDescriptor();
var idnull = charIDToTypeID( "null" );
var ref1 = new ActionReference();
var idActn = charIDToTypeID( "Actn" );
ref1.putName( idActn, actionName );
var idASet = charIDToTypeID( "ASet" );
ref1.putName( idASet, actionSet );
desc4.putReference( idnull, ref1 );
executeAction( idPly, desc4, DialogModes.NO );
}
Copy link to clipboard
Copied
Moving post to the Photoshop Scripting Forum.
Copy link to clipboard
Copied
Appreciate the help. This definitely points me in the right direction.
Copy link to clipboard
Copied
One possible idea you can do is use aspect ratio/orientation/name filters in Adobe bridge, highlight the files and go to Tools > Batch/image processor
and run your actions from there. This way you can batch process these before you need to use them.
Another idea is
From the actions panel, you can also add conditionals in your steps, so say you filtered out 2 pre-determined sizes. You can do
if document is square, run square action
else do this action.
if landscape do that, else do portrait print settings.
Copy link to clipboard
Copied
I had thought about batch processing them before use. That was my main idea actually. I did not know I could filter them with bridge though. Thanks for the tips!