bool IsValidEmail(string email) { try { var addr = new System.Net.Mail.MailAddress(email); return addr.Address == email; } catch { if (string.IsNullOrEmpty(email)) { return true; // Null is acceptable for this task } return false; } }