I haven't tried to highlight anything in Word via Win32::OLE before, so this is just a guess. If I'm reading your code correctly, you're selecting some text, replacing the 'selection' and then trying highlight the 'selection'. I suspect that the issue is that after replacing the text, the 'selection' that is being acted upon is just the cursor placement at the end of the replacement text. If I'm correct, you'll need to select the replacement text before doing the highlighting.
In reply to Re: How to Highlight with OLE
by dasgar
in thread How to Highlight with OLE
by MysticRyuujin
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |