Copy link to clipboard
Copied
Hey there good people,
Is it possible to find style A, and replace the style of the following paragraph which is in style B, to style C.
Does it make sense to anyone?
for example:
this text is in paragraph A this text is in paragraph A this text is in paragraph A this text is in paragraph A.
this text is in paragraph B this text is in paragraph B this text is in paragraph B this text is in paragraph B. <-this paragraph I wish to change to style C.
this text is in paragraph B this text is in paragraph B this text is in paragraph B this text is in paragraph B.
I found a similar question but the answer was in a script, and I have no idea where in InDesign I can change the code
.
help!
Copy link to clipboard
Copied
Hi Vraja,
indeed, this is something a script can do. And only a script.
Michel's solution, the script code, will only work if all involved paragraph styles are stored in the root of the Paragraph Styles panel.
It can be expanded easily ( for Michel or other scripters ) to fit your needs. To make it perfect one has to prepare some cases as well, like stories that have only one paragraph or no paragraph at all.
Regards,
Uwe
Copy link to clipboard
Copied
Hey Uwe,
Thanks for the reply, all paragraphs in my document have a paragraph style if that's what you mean by "stored in the root..."
the document is mostly one story,
What's the next stage? where does the code fit in?
I also develop html and css and php so I have little ideas about scripts...
Copy link to clipboard
Copied
Stored in the root of the Paragraph Styles panel means, that the styles are not nested in Paragraph Style Groups.
Go ahead and ask Michel on the other thread you linked to to expand the script to your needs.
Currently I'm not on my machine with InDesign installed so I cannot test anything.
It would be perfect if you can supply a test file.
Regards,
Uwe
Find more inspiration, events, and resources on the new Adobe Community
Explore Now