Use a script that is embeded directly in a PSD file

Upload Photoshop Scripts, download Photoshop Scripts, Discussion and Support of Photoshop Scripts

Moderators: Tom, Kukurykus

FausseFugue

Use a script that is embeded directly in a PSD file

Post by FausseFugue »

I don't know if anyone has thought of that before, but here's a script I did that allows you to run a script that is embeded in a .psd file. That way, if you have different files that need different scripts that you need to send to people, they don't need to install the new scripts in the Photoshop folder everytime. All they need is this little script and they can run any script you put in the psd files you send them.

It also creates an error log if there is an error in the embeded script.


Here are the instructions (the instructions can also be found in the .jsx file):

This tool lets you use a script that is embeded directly in a PSD file.
That way, you can send different PSD files with different SCRIPTs to people, and they will only need one SCRIPT (this one) to run them all.
It make less files to update, and less people playing in their Photoshop folders without really knowing what they're doing, so less place for mistakes.

Write you SCRIPT and CONTACT INFORMATION in your PSD file in "File/File Info..."
SCRIPT: Origin / Instructions
CONTACT INFO: Origin / Transmission Reference

The SCRIPT must be Javascript.
If you want to copy an action instead of a Javascript use the great ActionToJavascript tool by xbytor.

If you need to put more than one SCRIPT in a PSD file:
- Write each of them under a different Function().
- At the beginning of you SCRIPT write this:
ScriptList = [Function1Name, Function2Name, Function3Name]
A menu with a list of all the scripts to choose from will be automatically generated.
The menu is generated after the script has been run once, so the code in main Function() will run before the menu get's created.
If there is a Function() that you don't want to be a script on it's own, don't put it's name in the ScriptList.

The CONTACT INFO is information about the script programmer. (Name, Email, Phone, ...)
The CONTACT INFO is displayer whenever an error occurs in a script so people can contact you for help.



Please let me know if you have any comments, suggestions, complaints, ...