Click here to Skip to main content
15,892,809 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
plz help me to validate email address in domain ...
for example i want to check the email address like xyz@yahoo.com exists or not...
for gmail,rediff,hotmail etc etc....
Posted

The best way to check this, is to send a confirmation email within a code. You ask the user to enter the code in a text box and then you can check whether the sent code is equal to the entered code.
To send an email:
Sending an Email in C# with or without attachments: generic routine.[^]
VB.NET tip:
Sending an Email in C# with or without attachments: generic routine.[^]
 
Share this answer
 
Hi,

Try this

<asp:regularexpressionvalidator id="regexEmailValid" runat="server" validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" controltovalidate="tbEmail" errormessage="Invalid Email Format" xmlns:asp="#unknown">
 
Share this answer
 
Comments
Thomas Daniels 10-Dec-12 12:38pm    
This isn't what the OP asks. The OP asks how to check whether an email address does exist.
Your answer checks whether the entered email address is in a valid format.
ashokmmrk 10-Dec-12 13:02pm    
Please, Once Again read this

for example i want to check the email address like xyz@yahoo.com exists or not...

He clearly mention that Email address like xyz@yahoo.com exists or not...
Zaf Khan 10-Dec-12 23:10pm    
I agree with ProgramFox, The best way to see if an email EXISTS is to send an email to to the address - taking for granted that the FORMAT of the email address is correct.

The best way to VALIDATE if an email is FORMATTED correct is probably the way ashokmmrk says.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900