// layerName.jsx // Copyright 2006-2008 // Written by Jeffrey Tranberry // Photoshop for Geeks Version 2.0 /* Description: Using an alert(); to display current Layer's name. Set the name of the current layer to a string "Timmy" */ // enable double clicking from the // Macintosh Finder or the Windows Explorer #target photoshop // Make Photoshop the frontmost application app.bringToFront(); ///////////////////////// // SETUP ///////////////////////// ///////////////////////// // MAIN ///////////////////////// // Display a dialog with the current Layer's name alert(app.activeDocument.activeLayer.name); // Set the current Layer's name to "Timmy" app.activeDocument.activeLayer.name = "Timmy" // Display a dialog with the current Layer's name to make sure it has changed alert(app.activeDocument.activeLayer.name); ///////////////////////// // FUNCTIONS /////////////////////////