Skip to main content
Known Participant
January 11, 2023
解決済み

Insert object at the beginning of each sentences

  • January 11, 2023
  • 返信数 1.
  • 319 ビュー

Hi everyone,

Is it possible to insert an object with specific dimension at the beginning of every line of sentences using script?

 

Thank you!

このトピックへの返信は締め切られました。
解決に役立った回答 Peter Kahrel

You don't need a script. Do this:

1. Place the object somewhere, doesn't matter where.

2. Copy the object to the clipboard

3. Do this GREP replacement:

Find: ^

Change to: ~c

Which reads as 'place the content of the clipboard (~c) at the first insertion point (^) of each paragraph.

This works in CC2022 and later.

In earlier versions you do:

Find: ^(.)

Change to: ~c$1

(thats the digit 1 after the dollar symbol).

P.

返信数 1

Peter Kahrel
Community Expert
Peter KahrelCommunity Expert解決!
Community Expert
January 11, 2023

You don't need a script. Do this:

1. Place the object somewhere, doesn't matter where.

2. Copy the object to the clipboard

3. Do this GREP replacement:

Find: ^

Change to: ~c

Which reads as 'place the content of the clipboard (~c) at the first insertion point (^) of each paragraph.

This works in CC2022 and later.

In earlier versions you do:

Find: ^(.)

Change to: ~c$1

(thats the digit 1 after the dollar symbol).

P.

Known Participant
January 11, 2023

@Peter Kahrel you're one of the best! 

 

Thank you so much sir!