New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

OnFocus

The OnFocus client-side event handler is called when the input control gets focus.

Two parameters are passed to the event handler:

  • sender is the input control.

  • eventArgs is an instance of Sys.EventArgs.

The following example uses the OnFocus event to show an alert:

ASPNET
<telerik:RadTextBox RenderMode="Lightweight" ID="RadTextBox1" runat="server">
	<ClientEvents OnFocus="Focus" />
</telerik:RadTextBox>
JavaScript
<script type="text/javascript">
	function Focus(sender, eventArgs)
	{
		alert(sender.get_id());
	}
</script>

See Also

In this article
See Also
Not finding the help you need?
Contact Support