Width and Height of a picture object
Author Message
Width and Height of a picture object

I'm creating a control that has to show a picture centered on it. Only one
problem, the Width and Height properties of the Picture object are not in
pixels, not in twips. I don't remember the name of the unit. How can I
convert the unit from the picture to pixels?

Sun, 19 Jan 2003 03:00:00 GMT
Width and Height of a picture object
Hi Etienne:

Quote:
> the Width and Height properties of the Picture object are not in
> pixels, not in twips. I don't remember the name of the unit.

HiMetric

Quote:
> How can I  convert the unit from the picture to pixels?

Use the ScaleX and ScaleY methods.

Doug.

Sun, 19 Jan 2003 03:00:00 GMT
Width and Height of a picture object

Etienne,

Quote:
>I don't remember the name of the unit.

The unit is himetric.

Quote:
>How can I convert the unit from the picture to pixels?

Use the ScaleX and ScaleY methods.

Matt

============================================

VB+ - http://hem.spray.se/mattias.sjogren/
CodeHound - Free VB Search Engine
http://www.codehound.com

Sun, 19 Jan 2003 03:00:00 GMT
Width and Height of a picture object
How do I use the ScaleX and ScaleY methods?

Quote:
> Hi Etienne:

> > the Width and Height properties of the Picture object are not in
> > pixels, not in twips. I don't remember the name of the unit.

> HiMetric

> > How can I  convert the unit from the picture to pixels?

> Use the ScaleX and ScaleY methods.

> Doug.

Sun, 19 Jan 2003 03:00:00 GMT
Width and Height of a picture object
Etienne,

Quote:
>How do I use the ScaleX and ScaleY methods?

pixel_width = ScaleX(YourPicture.Width, vbHimetric, vbPixels)
pixel_height = ScaleY(YourPicture.Height, vbHimetric, vbPixels)

Matt

============================================

VB+ - http://hem.spray.se/mattias.sjogren/
CodeHound - Free VB Search Engine
http://www.codehound.com

Mon, 20 Jan 2003 03:00:00 GMT
Width and Height of a picture object
Hi Etienne:

Quote:
> How do I use the ScaleX and ScaleY methods?

Matt posted an example... you could have, however, looked it up in the VB
docs ;-)

Doug.

Mon, 20 Jan 2003 03:00:00 GMT

 Page 1 of 1 [ 6 post ]

Relevant Pages