操作系统

当前位置:澳门新莆京娱乐官网 > 操作系统 > 如何更改为支持多个地址

如何更改为支持多个地址

来源:http://www.drgigabytes.com 作者:澳门新莆京娱乐官网 时间:2020-04-21 00:01

如何更改为支持多个地址。代码如下:try{stringReceiveMailbox=Program.IniReadValue("Mail","ReceiveMailbox"State of Qatar;//选拔邮件地址stringReceiveType=Program.IniReadValue("Mail","ReceiveType"卡塔尔国;//选择邮件类型stringSendMailbox=Program.IniReadValue("Mail","SendMailbox"State of Qatar;//发送邮件地址stringSendMailboxPwd=Program.IniReadValue("Mail","SendMailboxPwd"卡塔尔(قطر‎;//发送邮件授权码MailMessagemage=newMailMessage(卡塔尔国;mage.From=newMailAddress(SendMailbox卡塔尔;mage.To.Add(newMailAddress(ReceiveMailbox卡塔尔(قطر‎State of Qatar;mage.Subject=Title;mage.Body=content;SmtpClientscp=newSmtpClient(State of Qatar;if(ReceiveType=="QQ邮箱"卡塔尔国{scp.Host="smtp.qq.com";}elseif(ReceiveType=="QQ集团邮箱"卡塔尔(قطر‎{scp.Host="smtp.exmail.qq.com";}elseif(ReceiveType=="163信箱"State of Qatar{scp.Host="smtp.163.com";}else{System.Windows.Forms.MessageBox.Show("一时并未有该邮筒"State of Qatar;}scp.EnableSsl=true;scp.UseDefaultCredentials=false;scp.Credentials=newNetworkCredential(SendMailbox,SendMailboxPwdState of Qatar;if(bool.Parse(Program.IniReadValue("Mail","StateBool"State of Qatar卡塔尔国卡塔尔(قطر‎scp.Send(mage卡塔尔;}catch(Exceptionex卡塔尔国{MessageBox.Show(Title+";邮件发送退步:检查填写是或不是有误!"卡塔尔(قطر‎;}}卡塔尔.Start(卡塔尔;选择地址变量如下[Mail]。。。ReceiveMailbox=myfoxx2365@163.comReceiveType=163邮箱。。。。以上代码只援助几个邮件接纳地址,怎样转移为支撑三个地方?举个例子ReceiveMailbox=myfoxx2365@163.com;1233@163.com;1236555@163.com

本文由澳门新莆京娱乐官网发布于操作系统,转载请注明出处:如何更改为支持多个地址

关键词:

上一篇:各位大神

下一篇:没有了