Answered
Copy Layer Name To Clipboard?
Hey folks,
i am looking for a script, which allows me to copy the name of my active layer to the clipboard.
Thank you for your help and best regrads,
S.
Hey folks,
i am looking for a script, which allows me to copy the name of my active layer to the clipboard.
Thank you for your help and best regrads,
S.
The following code should do the trick, it does exactly what you ask and nothing else:
// Copy Active Layer Name to Clipboard.jsx
#target photoshop
var doc = activeDocument;
var aLayer = doc.activeLayer.name;
var d = new ActionDescriptor();
d.putString(stringIDToTypeID("textData"), aLayer);
executeAction(stringIDToTypeID("textToClipboard"), d, DialogModes.NO);
Based on:
https://community.adobe.com/t5/Photoshop/Copy-foreground-RGB-values-to-clipboard/td-p/10529244
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.