What's new
Photoshop Gurus Forum

Welcome to Photoshop Gurus forum. Register a free account today to become a member! It's completely free. Once signed in, you'll enjoy an ad-free experience and be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

How can I rename a group using an action?


Messages
9
Likes
0
I have quite a bit projects which contain a group by the name "Cover" and I want to rename it to "Cover Group" using this action.

2.jpg

But into "Cover" layer group there is a layer with the same name. So when my action starts, instead of find and rename the group "Cover", renames the layer "Cover"!!!

1.jpg
1a.jpg

Any idea how can I define my action so to rename the group and not the layer?
 
If nothing works, you can include a script in your action...

JavaScript:
myLayerset  = activeDocument.layerSets.getByName("Cover");
myLayerset.name = "Cover Group";

- save as text and rename the extension from txt to jsx (e.g. cover.jsx)
- move the script to your scripts folder: C:\Program Files\Adobe\Adobe Photoshop 2022\Presets\Scripts
- (re)start photoshop
- now start recording your action at the position where you want to insert the script (can also be moved later to the right position)
- use the burger menu at the top right corner of the action panel and select "Insert Menu Item..." (a new window appears)
- select the script via > File > Scripts > cover
- select he OK-button in the windows which appears before
- stop recording of your action
- optionally move the new entry to the right position

Test it
 

Back
Top