This is not working as I intended it to, regardless it's running my if clause even if my email format is: something like hello@gmail.com not sure what is wrong here.
Regex RX = new Regex("^[a-zA-Z0-9]{1,20}@[a-zA-Z0-9]{1-20}.[a-zA-Z]{2,3}$");
if (!RX.IsMatch(textEmail.Text))
{
MessageBox.Show("Email format is not correct");
}
else
{
MessageBox.Show("Email format is CORRECT");
}
it should really run the else clause