This is a migrated thread and some comments may be shown as answers.

How to initiate AJAX Request with onBlur?

1 Answer 104 Views
Input
This is a migrated thread and some comments may be shown as answers.
briankb
Top achievements
Rank 2
briankb asked on 15 Jul 2008, 05:18 AM
I'm using controls from : RadControls for ASPNET AJAX Q1 2008

I'm creating a registration form and trying to use RADAjaxManager, and RADInput with standard validation controls. Everything is working fine except I need to have the validation run onBlur.

<tr> 
    <td class="label">*First Name:</td> 
    <td class="field"
        <telerik:RadTextBox runat="server" ID="FirstName" TextMode="SingleLine" Columns="8" MaxLength="20" InvalidStyleDuration="100" Width="145px"/> 
    </td> 
    <td class="validation"
        <asp:RequiredFieldValidator ID="RequireFirstName" runat="server" ControlToValidate="FirstName" ErrorMessage="First Name is Required" SetFocusOnError="true" Display="Dynamic"></asp:RequiredFieldValidator>                                             
    </td> 
</tr> 

How do I force the validation when the user leaves the Firstname field (onblur) using RAD Ajax?

1 Answer, 1 is accepted

Sort by
0
Kiara
Top achievements
Rank 1
answered on 17 Jul 2008, 01:18 PM
I am not sure whether you can force the validation client-side in this case, however intercepting the onBlur event of RadTextBox and performing ajax request (in ASP.NET AJAX web site) "behind the scenes" may do the trick.

I found this thread in the old Classic forums related to this subject:

http://www.telerik.com/community/forums/thread/b311D-baekga.aspx

Kiara
Tags
Input
Asked by
briankb
Top achievements
Rank 2
Answers by
Kiara
Top achievements
Rank 1
Share this question
or