DavidMan wrote:
I will keep in mind for the future that this is a Microsoft product and not everything will be without error; so I will use try/catch 🙂
I'm not so sure it is Microsoft's fault. Microsoft's recent Mac applications are very good, albeit very complex. Apple's AppleEvents, upon which the ScriptingBridge and AppleScript are based, is ancient, nasty stuff.
What I need to do now is to:
1. search for the text
2. if found, analyze it and replace it with the field codes.
3. Field codes, depending on the situation, should show different text.
4. GOTO 1.
I will try to work it out. If I have problems, shall I post the question again ini this topic or shall I close this one, give you your absolutely deserved "Solved" 10 points and open the new topic? Or will it be too much to open separate topic?
I just don't know the etiquette of this forum...
Once you think your question is resolved, just mark it solved and create new ones. If you feel a little context might be in order, include a link to one or more of your previous threads so people don't rehash old issues.
Unfortunately, it appears that if you have further issues, they might be more suited to Microsoft's own forums:
http://www.officeformac.com/productforums/. This question was appropriate here because it was generally about the Scripting Bridge.
Also, we don't know for sure what is causing this exception. It might be a good idea to go ahead and file a bug report on it:
http://developer.apple.com/bugreporter/. I think it is an Apple bug rather than a Microsoft bug, so start there.