style.pixelWidth (Property)

The pixel width of the styled element.


JScript - 3.0
Internet Explorer - 4.0
Opera - 5.0
Property/method value type:String primitive
JavaScript syntax:IEmyStyle.pixelWidth
CSS syntax:pixel-width: aWidth
Argument list:aWidthA sizing value

Although this is a read and write property, it is most likely to be useful for measuring the width of an object to get a numeric value without the trailing px suffix that you get when enquiring the style.width value.

The value in this property will be an integer defined in pixel measurement units only. This is regardless of the settings of the measurement units in the CSS attribute. Refer to the style.posWidth property for a more generalized value that can be operated on with different measurement units.

See also:Measurement units, style.pixelHeight, style.posHeight, style.posWidth, style.width