Reputation: 1391
I would like to insert single words with a specific style in a word document from a macro. Whenever I change the Style property of the Selection object or even of a range (e.g. ActiveDocument.Range(1,3)) the style of the whole paragraph is set.
How can I do this?
Upvotes: 3
Views: 3330
Reputation: 1437
You can simply select the word with your mouse (click&drag with the cursor) and then select the text properties such as the font, only the selected characters will change to that font.
Upvotes: -2
Reputation: 888273
You're trying to apply a paragraph style.
These styles can only be applied to complete paragraphs.
If you apply a character style, it will work fine.
Upvotes: 4