Events

RadEntry exposes the following events:

  • TextChanged: Occurs when the text is changed. The TextChanged event handler receives a TextChangedEventArgs argument containing data related to this event. The TextChangedEventArgs provides the following properties:

    • NewTextValue(string): which gets the new text value.
    • OldTextValue(string): that gets the old text value.
  • Completed: Occurs when the user finalizes the text in an entry with the return key.

Commands

RadEntry control exposes Command for its Completed event: CompletedCommand(ICommand).

Example

Here is the RadEntry definition in XAML with the TextChanged and Completed event handlers:

<StackLayout>
    <telerikInput:RadEntry x:Name="entry"
                           Keyboard="Numeric"
                           WatermarkText="Watermark Text" 
                           TextChanged="Entry_TextChanged"
                           Completed="Entry_Completed"/>
    <Label x:Name="textChangedLabel"/>
</StackLayout>

Here is a sample implementation of the TexhChanged event:

private void Entry_TextChanged(object sender, TextChangedEventArgs e)
{
    this.textChangedLabel.Text = $"Text changed from {e.OldTextValue} to {e.NewTextValue}";
}

and for the Completed event:

private void Entry_Completed(object sender, EventArgs e)
{
    this.textChangedLabel.Text = "User completed entering text";
}

You can find a working demo labeled Events in the Entry/Features folder of the SDK Samples Browser application.

See Also

In this article
Not finding the help you need? Improve this article