Friday, April 2, 2010

How to write this script

Hi,

I'm wanting to write a script that allows me to find a list of numbers in a text box and add or subtract one from them all.

So if I had a text box with ''5, 6, 7, 8''

I would like a script that changes it to ''6, 7, 8, 9''

can anyone help?

How to write this script

I forgot to add- I'm working with Indesign Cs3 and Applescript

thanks

How to write this script

Don't know AppleScript, but here's the basic.

You could start out by searching for all numbers in selected item (or document) - longest match (Any Digit in Indd find menu)

Loop on the resulting array, for each found value + 1.

Have a look at the Text -%26gt; Search script examples.

Good luck

No comments:

Post a Comment