How select text range


hi

i want select text in textframe.

i using method

textframe.characters.itembyrange(n,m).select();

but characters.itembyrange();

give error member not found if using long integer parameter in this.

for example text adobeindesign , want select indesign in adobeindesign.

characters.itembyrange(6,13);

 

how use characters.itembyrange() select text.

or there method select text range.

how use character or string type parameter in characters.itembyrange()

 

 

thanks.

@bill – "select()" method can work in 2 ways:

 

1. use app object that:

 

var whattoselect = textframe.characters.itembyrange(6,13);

app.select(whattoselect);

 

2. work object want select , replace selected object object:

 

var whattoselect = textframe.characters.itembyrange(6,13);

whattoselect.select(selectionoptions.replace_with);

 

or:

you can address object directly variable without selecting , instead (in case assigning fill color):

 

var whattoaddress = textframe.characters.itembyrange(6,13);

whattoaddress.fillcolor = "yellow";

 

 

also see indesign javascript reference guides at:

http://www.jongware.com/idjshelp.html

 

uwe



More discussions in InDesign Scripting


adobe

Comments

Popular posts from this blog

How to change text Component easybook reloaded *newbee* - Joomla! Forum - community, help and support

PProHeadless.exe has stopped working error when opening projects in Adobe Media Encoder CS6

Preconditions Failed. - Joomla! Forum - community, help and support