", and click "OK.
B). Create a user email address.
Select the newly created "hotmail.com" domain and click "add mailbox" in the right column. The add mailbox dialog box is displayed. In the "mailbox name" column, enter the email user name and set the user password, click "OK" to create the mailbox.
After the configuration is complete, add a. Net project. The steps are as follows:CodeSeeSMTP http://hqt.cnblogs.com/archive/2005/10/19/257991.html us
; } } When you pass in the correct user name and password for the sending mailbox, you always receive: The mailbox is unavailable. has no permission such error, English error: Mailbox unavailable. The server response Was:user has no permission.Actually, we use. NET sends a message when the custom client logs in based on the user name and password, and then uses the SMTP service to send the message. However, the newly registered 163 messa
Tidy up, a way to send mail in. NET, with the following code:1 Public Static stringNet_email (stringstrSendTo,stringSTRCC,stringSTRBCC,stringStrmailcontent,stringStrmailtitle,string[] strmailattachment,stringStrmailformat,stringStrserviceteam)2 {3 Try4 {5MailMessage Mmail =NewMailMessage ();6 using(Mmail)7 {8Strmailcontent = Strmailcontent.replace ("","");9 string[] List
Today, A. NET project involves sending emails. In fact, sending emails in. NET is very simple. You only need a few lines of code to send a simple text email. For example:Public void sendemail (string smtpserver, string fromaddr, string toaddr, string ccaddr, string bccaddr, string subject, string message, out int errnum, out string errtext)
{
Mailmessage message = new mailmessage ();
Message. To = toaddr;
M
receiving error messages when they are sent (the list of recipients repeats repeatedly)MailMsg. From = mailaddress_from;//Sender mailboxMailMsg. To.add (mailaddress_to);//Add Recipient email AddressMessage subjectMailMsg. Subject = "password";MailMsg. subjectencoding = Encoding.UTF8;Message bodyMailMsg. Body = Mailbody;MailMsg. bodyencoding = Encoding.UTF8;smtpclient.sendcompleted + = new Sendcompletedeventhandler (smtpclient_sendcompleted);//processing events after the
Example:
CopyCode The Code is as follows: The 163.com mailbox is supported in the early application, but not in the later application.
21cn.com seems to have abandoned SMTP support. It may only be available to paying users.
The mailbox of QQ.com needs to be set in the user account.
I took a Sina.com email address for testing.Can be sent. The Code is as follows:Copy codeThe Code is as follows: mailaddress from = new mailaddress ("sosuo8@sina.com ");Mailaddress to = new mailaddress ("ahuinan@21cn
The namespace used: system. net. Mail. Note that it is not system. Web. Mail. Here, you can use IIS on your machine to send emails.
Main Code:
String from = txtfrom. text; // The sender address
IIS configuration:
1. Right-click "Default SMTP virtual server" and choose Properties;
2. Select the "access" tab and click "Identity Authentication". The Selection b
Because the core does not take smptSo with MimekitTake 163 mailboxes as an examplevar message = new MimeMessage ();Message. From.add (New Mailboxaddress ("Wang Dazhao", "[email protected]");Message. To.add (New Mailboxaddress ("Wang Zhao", "[email protected]");Message. To.add (New Mailboxaddress ("Yang Xisi", "[email protected]");Message. Subject = "Work report of the Week";Textpart BODY = new Textpart (textformat.html){Text = "Send this week's work report"};using (smtpclient client = new SmtpCl
Solve | problems in. NET we often use MailMessage and smtpmail to cooperate with the letter, as long as the SMTP server is configured well, generally not a big problem
But recently I help www.danceshopper.com to do multilingual upgrade, found as long as the traditional mail, to Hotmail in the subject is garbled, content is garbled, but with Foxmail or Outlook received the client, the problem does not exist
Remember the port and SMTP server address (post: 25, URL: smtp.qq.com)
Sendmail. CS
1 Using System; 2 Using System. configuration; 3 Using System. net. mail; 4 Using System. net; 5 6 Namespace Parceldistribution. BLL 7 { 8 Public Class Sendmail 9 { 10 Private Readonly Smtpclient _ SMTP; 11 Private
Error message when sending an email using system. net. Mail
The configuration example is as follows:
Configuration error and prompt information:
Smtpserver error:
Unable to connect to the remote server
Port error:
Unable to connect to the remote server
Mailpassword error:
The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.