TextBox.TextAlignment Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets how the text should be horizontally aligned in the text box.
public:
property TextAlignment TextAlignment { TextAlignment get(); void set(TextAlignment value); };
TextAlignment TextAlignment();
void TextAlignment(TextAlignment value);
public TextAlignment TextAlignment { get; set; }
var textAlignment = textBox.textAlignment;
textBox.textAlignment = textAlignment;
Public Property TextAlignment As TextAlignment
<TextBox TextAlignment="textAlignmentMemberName"/>
Property Value
One of the TextAlignment enumeration values. The default is Left.
Remarks
This property provides the same functionality as the HorizontalTextAlignment property. If both properties are set to conflicting values, the last one set is used.