Please Note: This article is written for users of the following Microsoft Word versions: 2007, 2010, 2013, and 2016. If you are using an earlier version (Word 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Word, click here: Converting Inches to Points.
by Allen Wyatt
(last updated March 5, 2016)
A point is a typographical measurement that is quite small. Points are used to specify many typographical elements, such as font size and line spacing. This means that when writing macros, it may be helpful to convert from a familiar measurement (such as inches) to the equivalent measurement in points.
There are approximately 72 points per inch. This means that you could simply multiply a measurement in inches by 72 in order to derive a result. However, VBA also provides a method that does the conversion for you. Simply use the InchesToPoints method, as follows:
Selection.ParagraphFormat.SpaceAfter = InchesToPoints(0.1)
This example sets the space after a paragraph equal to one-tenth of an inch. VBA takes care of the necessary conversion from inches to points.
WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (12253) applies to Microsoft Word 2007, 2010, 2013, and 2016. You can find a version of this tip for the older menu interface of Word here: Converting Inches to Points.
Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!
You may have a need to find out how many times a certain text string occurs within a document. You can find out manually ...Discover More
Need to rename a disk file from within a macro? You can do it using the Name command, described in this tip.Discover More
If you need to quickly switch a text selection from one typeface to another, one way you can do it is with a macro. This tip ...Discover More
FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.