Okay, so I am having some issues with they way Applescript is dealing with the text located in the footnotes of a Microsoft Word Doc.
Will somebody else take a look at the result of running this code and maybe shed some light on why it is acting the way it is? I would be very appreciative, you would gain my undying devotion even…
Steps:
1.) Open MSWord (2004 or better)
2.) open a document, add text to the document, insert a footnote, add text at the footnote.
3.) put your insertion point in the text of the regular document, run the code below.
4.) put your insertion point in the text of the footnote and run the code below.
tell application "Microsoft Word"
set myRange to text object of selection
set myRange to move end of range myRange by a character item count 1
select myRange
end tell
I would expect the same result from both steps 3 and 4. myRange would be a text range of one character, one position to the right of your insertion point before you ran the code. However, it fails miserably when the insertion point is inside the footnote. Is this an issue with applescript, or am I not accessing the text object inside of the footnote correctly? It seems to work just fine within the footnote up until you hit the “move end of range”, where it gets upset
any help shedding light on this would be awesome.
thank you mucho
Browser: Firefox 2.0.0.9
Operating System: Mac OS X (10.5)