<tfoot id='o8RTx'></tfoot>
    1. <legend id='o8RTx'><style id='o8RTx'><dir id='o8RTx'><q id='o8RTx'></q></dir></style></legend>

        <bdo id='o8RTx'></bdo><ul id='o8RTx'></ul>

      1. <small id='o8RTx'></small><noframes id='o8RTx'>

        <i id='o8RTx'><tr id='o8RTx'><dt id='o8RTx'><q id='o8RTx'><span id='o8RTx'><b id='o8RTx'><form id='o8RTx'><ins id='o8RTx'></ins><ul id='o8RTx'></ul><sub id='o8RTx'></sub></form><legend id='o8RTx'></legend><bdo id='o8RTx'><pre id='o8RTx'><center id='o8RTx'></center></pre></bdo></b><th id='o8RTx'></th></span></q></dt></tr></i><div id='o8RTx'><tfoot id='o8RTx'></tfoot><dl id='o8RTx'><fieldset id='o8RTx'></fieldset></dl></div>

        asp.net 邮件添加回复

        时间:2023-10-05
        • <bdo id='oZhC5'></bdo><ul id='oZhC5'></ul>
          <tfoot id='oZhC5'></tfoot>
          • <i id='oZhC5'><tr id='oZhC5'><dt id='oZhC5'><q id='oZhC5'><span id='oZhC5'><b id='oZhC5'><form id='oZhC5'><ins id='oZhC5'></ins><ul id='oZhC5'></ul><sub id='oZhC5'></sub></form><legend id='oZhC5'></legend><bdo id='oZhC5'><pre id='oZhC5'><center id='oZhC5'></center></pre></bdo></b><th id='oZhC5'></th></span></q></dt></tr></i><div id='oZhC5'><tfoot id='oZhC5'></tfoot><dl id='oZhC5'><fieldset id='oZhC5'></fieldset></dl></div>

            • <legend id='oZhC5'><style id='oZhC5'><dir id='oZhC5'><q id='oZhC5'></q></dir></style></legend>

                  <tbody id='oZhC5'></tbody>

                <small id='oZhC5'></small><noframes id='oZhC5'>

                1. 本文介绍了asp.net 邮件添加回复的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  如何在 ReplayTo 字段中添加与发件人不同的电子邮件?似乎 MailMessage.ReplyTo 已被弃用,所以我尝试使用 ReplyToList 代替.

                  How can i add a a different email then the sender in the ReplayTo field ? Seems MailMessage.ReplyTo is deprecated so I'm trying to use ReplyToList instead.

                  但它告诉我

                  Property or indexer 'System.Net.Mail.MailMessage.ReplyToList' cannot be assigned to -- it is read only
                  

                  到目前为止,这是我的代码:

                  Here is my code so far:

                  var reply = new MailAddressCollection();
                   reply.Add("test@test.com");
                   MailMessage mail = new MailMessage(senderEmail,usr.Email,"subject","message");
                   mail.ReplyToList = reply;
                   var smtp = new SmtpClient();
                   smtp.Send(mail);
                  

                  推荐答案

                  你不能设置它为一个全新的MailAddressCollection,但是你可以直接添加到现有的MailAddressCollection,像这样:

                  You can't set it to a whole new MailAddressCollection, but you can add directly to the existing MailAddressCollection, like this:

                  MailMessage mail = new MailMessage(senderEmail,usr.Email,"subject","message");
                  mail.ReplyToList.Add("test@test.com");
                  var smtp = new SmtpClient();
                  smtp.Send(mail);
                  

                  这篇关于asp.net 邮件添加回复的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:我可以在不通过 SMTP 服务器验证的情况下发送电子邮件吗? 下一篇:邮件发送失败.无法将数据写入传输连接

                  相关文章

                    <legend id='sr9Rb'><style id='sr9Rb'><dir id='sr9Rb'><q id='sr9Rb'></q></dir></style></legend>
                    1. <i id='sr9Rb'><tr id='sr9Rb'><dt id='sr9Rb'><q id='sr9Rb'><span id='sr9Rb'><b id='sr9Rb'><form id='sr9Rb'><ins id='sr9Rb'></ins><ul id='sr9Rb'></ul><sub id='sr9Rb'></sub></form><legend id='sr9Rb'></legend><bdo id='sr9Rb'><pre id='sr9Rb'><center id='sr9Rb'></center></pre></bdo></b><th id='sr9Rb'></th></span></q></dt></tr></i><div id='sr9Rb'><tfoot id='sr9Rb'></tfoot><dl id='sr9Rb'><fieldset id='sr9Rb'></fieldset></dl></div>
                    2. <small id='sr9Rb'></small><noframes id='sr9Rb'>

                      <tfoot id='sr9Rb'></tfoot>
                        <bdo id='sr9Rb'></bdo><ul id='sr9Rb'></ul>