using System.Text.RegularExpressions;
public class Base
{
private static bool isValidEmail(string email)
{
Regex r = new Regex(@"^([0-9a-zA-Z]([-\.\w]*[0-9a-zA-Z])*@([0-9a-zA-Z][-\w]*[0-9a-zA-Z]\.)+[a-zA-Z]{2,9})$");
if (!string.IsNullOrEmpty(email))
return r.IsMatch(email);
else
return false;
}
}