Automating tasks : Running saved scripts
 
Running saved scripts
You can run a saved script by selecting the script from the Select Script drop-list, or by navigating to the folder where the script is located. You can also add folders containing scripts to the Select Script drop-list.
You can also run multiple scripts in a sequence. If you have a single script with too many operations, you may want to spread the tasks into several scripts that you can run in a specific order. This modularity makes it easier for you to maintain scripts and allows you to work around memory limitations.
When you have scripted actions that involve dialog boxes, you can choose to run the script in Silent mode, so the dialog boxes do not appear as the script runs. Conversely, you can choose to run the script in Interactive mode, so that dialog boxes appear for user interaction. For more information, see To set a playback mode for a script action or command.
To run a script listed in the Select Script drop-list
Edit workspace 
1 On the Script toolbar, click the Select Script drop-list to display the scripts.
2 Click the script that you want to run.
3 Click the Run Selected Script button .
You can add any folder to the list of folders that the Select Script drop-list displays by clicking the drop-list and clicking the File Locations button . In the File Locations dialog box, click Add and navigate to the folder that contains the scripts.
To run a script not listed in the Select Script drop-list
Edit workspace 
1 On the Script toolbar, click the Run Script button to open the Run Script dialog box.
2 Choose the folder that contains the script you want to run.
3 Select the script.
4 Click Open.
To run multiple scripts
Edit workspace 
1 Click an open image to make it active.
2 On the Script toolbar, click the Run Multiple Scripts button to open the Run Multiple Scripts dialog box.
3 From the left pane, double-click the scripts that you want to run
4 Click Run.
To run scripts on all open images
Edit workspace 
1 Run a script or multiple scripts on an image.
2 Open the History palette by pressing F3.
3 Right-click the scripts in the History palette and choose Apply to other open documents.
You can also run scripts on another open image by dragging the actions from the History palette and dropping them onto the image.
To run the last executed script or multiple scripts on another open image, click the image to make it active, and then press Ctrl + Y.
To toggle between Interactive and Silent script playback mode
Edit workspace 
Click the Toggle Execution Mode button on the Script toolbar.
When the button has a border around it, it is in Interactive mode.
If you’ve edited the script and set part or all of it to run in either Silent or Interactive mode, clicking the Toggle Execution Mode button will not override that setting. If a script is set to Default mode, the state of this button will override the Toggle Execution Mode setting. The Toggle Execution Mode setting affects only those steps and commands set to Default mode within the script.