Graphic Design Stack Exchange is a question and answer site for Graphic Design professionals, students, and enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have created a Photoshop action which:

  1. Duplicates the current image.
  2. Merges all visible layers.
  3. Removes hidden layers.
  4. Rearranges parts of image.
  5. Adds the layer to a group.
  6. Displays user interface to "Duplicate Layer Group" back to the original image. (Using action "Insert Menu Item...")
  7. Closes the image without saving.

This is working but I would like to automatically duplicate the layer group back to the original image without having to select it from a drop-down box.

See Video:

Is there a way to do this? perhaps by adding a script or something?

share|improve this question
What do you mean by "duplicate the layer group back to the original image"? If I duplicate a layer group by dragging the group to the new layer icon while recording an action it produces a Duplicate current layer item, and this item when played succeeds in copying the selected layer group. Is that what you want? – Mr.Wizard Jan 20 '13 at 22:25
@Mr.Wizard I am using Layer | Duplicate Group... which displays a dialog box which allows you to duplicate the layer group to a different image. This is useful because it ensures that the layer is positioned correctly when its content is surrounded by transparent space. I have uploaded a video to demonstrate: – Lea Hayes Jan 21 '13 at 0:55
Don't use "insert menu item" when you are adding duplicate group to the action, that is the reason why it is showing the dialog box. The icon next to the checkmark means that a dialog box will appear. – Joonas Jan 21 '13 at 6:50
I am impressed that you made a video to illustrate. Thank you. – Mr.Wizard Jan 21 '13 at 10:49
@Joonas I had to use the "insert menu item" because otherwise the layer is duplicated to back to the wrong image. The action will be used extensively when creating these images which means that it is very likely that multiple images will be open of a similar nature. So it is important that an automatic approach duplicates the layer back to the original image. – Lea Hayes Jan 21 '13 at 18:57
up vote 2 down vote accepted

Your problem may require scripting. The name of the original image is included in the recorded action so it only works for that particular image or at least one with the same file name.

A workaround that might be acceptable (though I admit hardly ideal) is to first duplicate your original image to rename it something generic, then run the action on that. For example, this duplicates a starting image as TEST then duplicates that, selects all layers and groups them, then copies that layer group back to TEST:

Action crop

share|improve this answer
Thanks. Do you know how I can go about creating a script to achieve this? – Lea Hayes Jan 21 '13 at 18:55
I realize that this is a new question, so I have asked it here:… – Lea Hayes Jan 21 '13 at 19:32

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.