ASPxTextEdit.TextChanged Event
Fires when the control accepts the new text value entered by a user.
Namespace: DevExpress.Web
Assembly: DevExpress.Web.v25.2.dll
NuGet Package: DevExpress.Web
Declaration
Event Data
The TextChanged event's data class is EventArgs.
Remarks
The control raises the TextChanged event after it accepts the text value entered by a user. To accept the new value, a user can press Enter, or defocus the text field (press Tab, or click another page area).
To allow the editor to raise the server-side TextChanged event, use one of the following options:
- Set the AutoPostBack property to
true. - In the client-side TextChanged event handler, set the processOnServer argument property to
true. In this case, the editor raises the client-side event and then raises the server-sideTextChangedevent.
<dx:ASPxComboBox ID="ASPxComboBox1" runat="server" AutoPostBack="true" ClientInstanceName="combo"
OnTextChanged="ASPxComboBox1_TextChanged">
<Items>
<dx:ListEditItem Text="Item1" Value="1" />
<dx:ListEditItem Text="Item2" Value="2" />
</Items>
</dx:ASPxComboBox>
<dx:ASPxSpinEdit ID="ASPxSpinEdit1" runat="server" Number="0"
MinValue="0" MaxValue="1">
</dx:ASPxSpinEdit>
protected void ASPxComboBox1_TextChanged(object sender, EventArgs e) {
ASPxSpinEdit1.Value = ASPxComboBox1.SelectedIndex;
}
ASPxGridLookup Limitation
- When the ASPxGridLookup editor’s value changes, the editor sends a callback to the server to synchronize its value with the internal ASPxGridView control’s selection. Because of this, the server-side
TextChangedevent fires before the client-side TextChanged event.
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the TextChanged event.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.