It doesn't create the range!

Hello,

With MS Word, I am unable to create a range by specifying the limits with a character number.
See my partial script below.
What am I doing wrong?


set myRange to create range active document start (character 1 of text object of section 1 of active document) end (character 30 of text object of section 1 of active document)
select myRange
copy object selection

The range isn’t created…

Thanks for the help.

Andrew

Well I found my mistake. With the words: Start of content / En of content. It works. The range is created.


set myRange to create range active document start (start of content of character 1 of text object of section Compteur of active document) end (end of content of character (NbCharacters - 1) of text object of section Compteur of active document)