Asked By
Walter Neff
30 points
N/A
Posted on - 10/29/2012
I like to create ASP.NET file customer page in CRM 4.0, I need the CRM validate email address in text box control function similar with what is in CRM 4.0. I want to know the technique an if the coding in JavaScript for email validation is available.
JavaScript coding available to crm validate email address
Email validation with Javascript is simple. Javascript only validates the correct format of an email address, it will not be able to validate if the address is actually present or not. Following is a code snippet of Javascript email validation.
function ValidateEmailAddress( myInput)
{
var format = /^w+([.-]?w+)*@w+([.-]?w+)*(.w{2,3})+$/;
if(myInput.value.match(format))
{
return true;
}
else
{
alert("You have entered an invalid email address!");
return false;
}
}
In place of an alert, you can use any kind of error message notification as you desire.