Skip to main content
Known Participant
January 26, 2022
Question

Select all text from one paragraph or character style

  • January 26, 2022
  • 4 replies
  • 759 views

Is there a way to select all text from one paragraph or character style in InDesign?

I search the forum and see that there are some scripts but I faild to use them and I would be grateful if someone could explain this to me.

Thanks!

This topic has been closed for replies.

4 replies

brian_p_dts
Community Expert
January 27, 2022

Putting aside the issue as to whether you should outline the text (as it could cause a host of issues, such as flow issues across threaded frames), here's a script that would do it by character style. Use at your own risk.

 

var main = function() {
    var charStyleToFind = "Style1";
    try { 
        var doc = app.activeDocument; 
    } catch(e) {
        return;
    }
    app.findTextPreferences = null;
    app.findTextPreferences.appliedCharacterStyle = charStyleToFind;
    var fs = doc.findText();
    for (var i = fs.length - 1; i >= 0; i--) {
        try {
            fs[i].createOutlines();
        } catch(e) {}
    }
}
main();

 

Known Participant
February 3, 2022

Thanks for the script!

Community Expert
January 26, 2022

"it is not possible to select all text at once from that character style from each text frame on one page."

 

Of course. m1b already said that in the first reply of this thread:

"You can't actually "select" it because you can't select non-consecutive text ranges."

 

To select text that is in non-consecutive text ranges is simply not a feature in InDesign.

 

Regards,
Uwe Laubender

( ACP )

jmlevy
Community Expert
January 26, 2022

No need for a script. Just run a find/change and leave the find field empty

Click on the magnifying glass icon to choose the paragraph (or character) style you need to find

Known Participant
January 26, 2022

Hi jmlevy.

 

Thanks for your reply. I try to select text on your way but only one text line can be selected, it is not possible to select all text at once from that character style from each text frame on one page.

Peter Spier
Community Expert
January 26, 2022

While you cannot select al the text at once, you CAN specify the change format ad press the Change All button...

m1b
Community Expert
January 26, 2022

Hi @славишап52914384, can you give us a bit more information? What do you plan to do with the text? You can't actually "select" it because you can't select non-consecutive text ranges.

- Mark

Known Participant
January 26, 2022

I have many text frames on one page and some frames are inside some objects (circle or rectangle) and I want to select all text on that page to can outline them. All text frames are in one layer and I can select them by clicking on a small layer rectangle but text inside the object can't be selected so I need a way to select that text at once based on the paragraph or character style applied to that text if possible.

jmlevy
Community Expert
January 26, 2022

I want to select all text on that page to can outline them

Why would you want to outline the text? A printer requisit?