Please Note: This article is written for users of the following Microsoft Word versions: 97, 2000, 2002, and 2003. If you are using a later version (Word 2007 or later), this tip may not work for you. For a version of this tip written specifically for later versions of Word, click here: Controlling the Italic Text Attribute.

Controlling the Italic Text Attribute

by Allen Wyatt
(last updated May 11, 2013)

3

Word allows a rich set of formatting attributes for text in a document. You can control the italic attribute in your macros by setting the value of the italic property. The syntax if you are using VBA is as follows:

Selection.Font.Italic = toggle

where toggle is either False (turns off the italic attribute) or True (turns on the italic attribute).

If you omit a toggle value, the statement will simply change the current setting of the italic attribute—italic text becomes non-italic and vice-versa.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (730) applies to Microsoft Word 97, 2000, 2002, and 2003. You can find a version of this tip for the ribbon interface of Word (Word 2007 and later) here: Controlling the Italic Text Attribute.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He  is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Sending an E-mail when a Due Date is Reached

Wouldn't it be great if Excel could automatically e-mail you when a due date is reached? It can, if you are using Outlook and ...

Discover More

Using Copy and Paste for Formatting

Want to copy formatting from one cell and paste it into another cell? It's easy to do if you use the Paste Special feature of ...

Discover More

Viewing Footnotes and Endnotes

Footnotes and endnotes are normally visible with the rest of your document, but such visibility is dependant on which viewing ...

Discover More

The First and Last Word on Word! Bestselling For Dummies author Dan Gookin puts his usual fun and friendly candor back to work to show you how to navigate Word 2013. Spend more time working and less time trying to figure it all out! Check out Word 2013 For Dummies today!

More WordTips (menu)

Determining How Many Windows are Open

You can open multiple documents at the same time in Word, and each document occupies its own document window. Here's a way ...

Discover More

Determining if Overtype Mode is Active

Your macro may need to determine if the user has overtype mode turned on. You can find out the overtype status easily by ...

Discover More

Printing Graphic Thumbnails

If you are doing work with a lot of graphics, it may be helpful to create a summary page that contains thumbnail ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is five minus 4?

2014-10-22 15:03:21

Kevin

I think if you are trying just to toggle the italic attribute of text in VBA, the syntax is Selection.Font.Italic = wdToggle. Just leaving the toggle value blank doesn't seem to work for me.


2014-10-22 15:02:46

Kevin

I think if you are trying just to toggle the italic attribute of text in VBA, the syntax is Selection.Font.Italic = wdToggle. Just leaving the toggle value blank doesn't seem to work for me.


2014-10-22 15:02:41

Kevin

I think if you are trying just to toggle the italic attribute of text in VBA, the syntax is Selection.Font.Italic = wdToggle. Just leaving the toggle value blank doesn't seem to work for me.


This Site

Got a version of Word that uses the menu interface (Word 97, Word 2000, Word 2002, or Word 2003)? This site is for you! If you use a later version of Word, visit our WordTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.