0

I have written a code to validate a string.but i am getting an error in the 3rd sentence as "the name "NullToString"does not exist in the current context"...can anyone help me out...

public static bool isEmail(string inputEmail)
        {
            inputEmail = NulltoString(inputEmail);
            string strRegex = @"^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}" +
            @"\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\" +
            @".)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$";
            Regex re = new Regex(strRegex);
            if (re.IsMatch(inputEmail))
                return (true);
            else
                return (false);
        }
3
Contributors
2
Replies
4
Views
7 Years
Discussion Span
Last Post by nick.crane
0

Should be a Discussion Topic instead of a Code Snippet... other than that tho, on my way out the door and hopefully someone else can help you out :)

Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.