Share via


IXRTextBox::SetIsReadOnly (Compact 2013)

3/28/2014

This method sets a value that determines whether the user can change the text in this text box.

Syntax

virtual HRESULT STDMETHODCALLTYPE SetIsReadOnly(
    bool IsReadOnly
) = 0; 

Parameters

  • IsReadOnly
    [in] Boolean that determines whether the user can change the text in this text-box control. Set this value to true if the text box should be read-only; otherwise, set it to false.

Return Value

Returns an HRESULT that indicates success or failure.

Remarks

If this text box is read-only, no user input or edits are allowed, but programmatic changes can be made. The user can still select text, and the cursor still appears. The KeyUp and KeyDown events are specified as handled.

.NET Framework Equivalent

System.Windows.Controls.TextBox.IsReadOnly

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

IXRTextBox
IXRTextBox::GetIsReadOnly