I am trying to set focus on a radtextbox using the following function called on the ClientEvents-OnBlur event:
The problem is that when I remove the text and tab away, focus is not set. If I continue tabbing back to that field the onblur event fires again but it does set focus. Why is this failing on my first onBlur event being fired and successful on the second onBlur event firing?
function ValidateTitle(oTitle, args) {
if (oTitle.get_value()=='') {
oTitle.focus();
}
}
<telerik:RadTextBox
ID="txtTitle"
runat="server"
Rows="3"
TextMode="MultiLine"
Width="362px"
MaxLength="4000"
ToolTip="Title"
CausesValidation="True"
ClientEvents-OnBlur="ValidateTitle">
</telerik:RadTextBox>
The problem is that when I remove the text and tab away, focus is not set. If I continue tabbing back to that field the onblur event fires again but it does set focus. Why is this failing on my first onBlur event being fired and successful on the second onBlur event firing?
function ValidateTitle(oTitle, args) {
if (oTitle.get_value()=='') {
oTitle.focus();
}
}
<telerik:RadTextBox
ID="txtTitle"
runat="server"
Rows="3"
TextMode="MultiLine"
Width="362px"
MaxLength="4000"
ToolTip="Title"
CausesValidation="True"
ClientEvents-OnBlur="ValidateTitle">
</telerik:RadTextBox>