密码恢复控制问题 [英] Problem with passwordRecovery Control

查看:95
本文介绍了密码恢复控制问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个网站,我想在其中实施登录控件.除密码恢复"控件外,所有控件均正常工作.

控件生成错误.错误如下

必须在发件人"属性或system.net/mailSettings/smtp配置部分中指定发件人电子邮件地址.

我现在不该做什么.
请帮助我.

I am developing a website, where I want to implement Login controls. All the Controls are working properly except Password Recovery control.

The control is generating an error. Error is as follows

A from e-mail address must be specified in the From property or the system.net/mailSettings/smtp config section.

I don''t now what to do.
please help me.

推荐答案

我认为这是因为您正尝试通过SmtpClient类发送电子邮件.它正在尝试从属性或配置部分中查找此MailMessage的发件人地址,但无法在此处找到它.您可以在调用Send()时指定发件人地址,也可以使用MailMessage的发件人属性或在配置文件中指定发件人地址.在 MSDN [链接 [
I think thats happening because you are trying to send an email via SmtpClient class. It is trying to look up the from address for this MailMessage from the property or config section and could not able to find it there. You can specify the From address when you call Send() or with the From property of MailMessage or in the config file. The System.Net config section is defined at MSDN[^]. You can also check this link[^] as well.

Good luck,
OI


这篇关于密码恢复控制问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆