Hi Friends
Wish U Happy New Year 2009
I Need Email sending Concept in asp.net
If possible sent me some notes about email concept and
sample codings....
Waiting for valuable Rply
Thanks with
vishnukumar SR
Hi Friends
Wish U Happy New Year 2009
I Need Email sending Concept in asp.net
If possible sent me some notes about email concept and
sample codings....
Waiting for valuable Rply
Thanks with
vishnukumar SR
Jump to PostHi
1)You can import system.net.mail
2) You can use this code
Dim mm As New MailMessage(fromid, toid, subject, body) mm.IsBodyHtml = True Dim smtp As New SmtpClient smtp.Send(mm)
3)You can set the mail setting on WEB.CONFIG
<system.net> <mailSettings> <smtp> <network host="localhost" port="23"/> …
using System.Net.Mail;
MailMessage msg = new MailMessage(strFrom, strTo, strSubject, strBody);
SmtpClient cls = new SmtpClient("ur sys IP or n/w IP");
Attachment atchmntn = new Attachment(abc/xyz....ur attachment);
atchmntn.Name = "abc.jpg";
msg.Attachments.Add(atchmntn);
You can use this code.
If u get any problem chk ur SMTP settings particularly Relay Restrictions settings....
Hope this helps you...
Regards
Anil Reddy
using System.Net.Mail;
MailMessage msg = new MailMessage(strFrom, strTo, strSubject, strBody);
SmtpClient cls = new SmtpClient("ur sys IP or n/w IP");
Attachment atchmntn = new Attachment(abc/xyz....ur attachment);
atchmntn.Name = "abc.jpg";
msg.Attachments.Add(atchmntn);You can use this code.
If u get any problem chk ur SMTP settings particularly Relay Restrictions settings....
Hope this helps you...
Regards
Anil Reddy
HI Sir,
How Can I Create STMP Server ? Plz Explain me sir
regards,
vishnukumar SR
Hi
1)You can import system.net.mail
2) You can use this code
Dim mm As New MailMessage(fromid, toid, subject, body)
mm.IsBodyHtml = True
Dim smtp As New SmtpClient
smtp.Send(mm)
3)You can set the mail setting on WEB.CONFIG
<system.net>
<mailSettings>
<smtp>
<network host="localhost" port="23"/>
</smtp>
</mailSettings>
</system.net>
I hope this is useful for you
hi,
you can use this code to send mails
Sub sendmail()
Dim msg As New MailMessage
msg.From = txtEmail.Text
msg.To = "info@yahoo.co.in"
'msg.To = "name1@yahoo.com"
msg.Bcc = "name2@yahoo.co.in"
msg.Subject = " Demo Info "
msg.BodyFormat = MailFormat.Html
Dim str As String
msg.Body = mail(str)
msg.Priority = MailPriority.High
Try
SmtpMail.SmtpServer = "localhost"
SmtpMail.Send(msg)
Catch ex As HttpException
Catch ex As Exception
Finally
End Try
End Sub
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.