Word Height and Width NUmbers

P

Paul

I passing Excel charts and tables thru' to a word document and reizzing them in VBA,

.InlineShapes(1).Height = 75
.InlineShapes(1).Width = 150

What do the 75 and 150 refer to as it isn't millimetres?

thanks
 
J

Jay Freedman

Hi Paul

These measurements, and most of the ones used in VBA, are in "points".
By definition 1 inch = 72 points, so one point is a little more than
1/3 of a millimetre.

If you'd rather work in more familiar units, you can use the
conversion functions like this:

.InlineShapes(1).Height = MillimetersToPoints(75) ' 75 mm
or
.InlineShapes(1).Height = CentimetersToPoints(7.5) ' 7.5 cm

and in the other direction

MsgBox PointsToMillimeters(.InlineShapes(1).Height) & " mm"
or
MsgBox PointsToCentimeters(.InlineShapes(1).Height) & " cm"
 
P

Paul

Thank you, Soon after the post I found a reference to 1 point = 1/72 inch, but the conversion functions are great much easier to work with

Thanks again
Paul
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top