Please can anyone help me out to solve my problem.

m developing one site in which i want to send one page to friend.
now m using System.web.mail and using the method in that. but its not working.
so Please can anyone give me the code to send the mail..

In advanced thanks dear.

Please Help me. m not getting any error but why its not working . m stucked now.

with Regards,
Vishakha

Recommended Answers

All 5 Replies

Use system.net.mail.

There are lots of examples out there. If you are still having trouble, holler back and I will post.

Use system.net.mail.

There are lots of examples out there. If you are still having trouble, holler back and I will post.

Thanks Dear!

I have used it and my problem solved. but it is not going to the mail box of my gmail account.
it is getting me in mailroot folder.
is it right?
or some problem is still der.

To send through GMAIL, there are a few things you need to do to make it work with .NET.

(1) Enable POP and/or IMAP in the GMAIL settings
(2) Enable SSL & use Port 587

Dim ObjectMail As New SmtpClient("smtp.gmail.com", 587)
ObjectMail.EnableSsl = True

Good luck,

Eric

u can set the access in Relay property of SMTP in IIS,for the local IP,then u can fire emails from your system.

i have done this. Thanks

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.