• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Update text object to match text layer name?

Community Beginner ,
Jul 21, 2022 Jul 21, 2022

Copy link to clipboard

Copied

Looking for a way to (hopefully in mass) update a text object on the artboard (eg "101") to match its corresponding name in the layers panel after I change it (eg "101,A1")

So the text object on the artboard is "101" and I change the layer name to "101,A1", I am looking for a way to update the text object to "101,A1", without manually typing it into the text object.

Any scripts out there?

Screen Shot 2022-07-21 at 9.26.19 AM.png

TOPICS
Feature request , Scripting , Tools , Type

Views

189

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
LEGEND ,
Jul 21, 2022 Jul 21, 2022

Copy link to clipboard

Copied

LATEST

This would update any text frame contents in the active document to it's object name:

updateContent();

function updateContent() {
    var aDoc = app.activeDocument;
    for (i = 0; i < aDoc.textFrames.length; i++) {
        aDoc.textFrames[i].contents = aDoc.textFrames[i].name;
    }
}

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines