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

RadMaskedInput & email addresses

1 Answer 285 Views
Input
This is a migrated thread and some comments may be shown as answers.
Karl Wilkens
Top achievements
Rank 1
Karl Wilkens asked on 08 May 2009, 10:21 PM
It states in the demo and general areas that you can use RadMaskedInput for email, but I cant find any examples and was not sure how to achieve this. Does anyone have any suggestions? Thanks.

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 11 May 2009, 05:23 AM
Hi Karl,

I hope the approach to use RadTextBox with RegularExpressionValidator in order to validate the input for e-mail address is suitable for you.

aspx:
 
<telerik:RadTextBox ID="RadTextBox1" runat="server"
</telerik:RadTextBox> 
<asp:RegularExpressionValidator 
    id="emailValidator" 
    runat="server" 
    Display="Dynamic" 
    ErrorMessage="Please, enter valid e-mail address." 
    ValidationExpression="^[\w\.\-]+@[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]{1,})*(\.[a-zA-Z]{2,3}){1,2}$" 
    ControlToValidate="RadTextBox1"
</asp:RegularExpressionValidator> 
<br/> 
<asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Submit" />  

Thanks,
Shinu.
Tags
Input
Asked by
Karl Wilkens
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or