Export (0) Print
Expand All
Key
M11
M12
M21
M22
Tag
Uri
X1
X2
Y1
Y2
Expand Minimize
This topic has not yet been rated - Rate this topic

Width (UIElement)

Silverlight

Gets or sets the width of an object.

<object Width="Double"  .../>
value = object.Width
object.Width = value

Type: Double

The width of the object, in pixels.

This property is read/write. The default value is 0.

Many of the UIElement derived objects are also derived from Shape. Not all the Shape classes typically use Height or Width to specify their appearance. Instead, they use specific properties that might define a set of points. In this case, a Height or Width is calculated but not typically set directly.

TextBlock is a container object that displays text within it. The size of that text can influence the size of the rendered TextBlock. Therefore, TextBlock supports two additional properties that expose that calculated size: ActualHeight and ActualWidth.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.