Membership.CreateUser()被赋予例外!! [英] Membership.CreateUser() is given an Exception !!
问题描述
嗨开发者,
希望每个人都做得很好..
我正在努力工作ASP.net会员资格也与我的APP集成,
首先我创建了一个示例网络应用程序来创建新用户到会员桌
我已经将成员资格标签添加到web.config并将连接字符串更改为我的数据库connString我也将ApplicationName设置为\。
然后我使用以下代码添加CreateUserWizard控件:
Hi Developers,
Hope everybody doing well ..
I'm trying to work with ASP.net membership also integrated with my APP,
first I've created a sample web app to create the new users to membership table
I've Added the membership tag to web.config and change the connection string to my Database connString also I set ApplicationName to "\".
then I added "CreateUserWizard" control with the following code:
Membership.CreateUser(CreateUserWizard1.UserName,CreateUserWizard1.Password,CreateUserWizard1.Email);
但是当我运行代码时,我遇到以下异常:confused ::
http://www.m5zn.com/newuploads/2015/03/21/jpg//9a5f11556559e6b.jpg
任何人都可以提供帮助:(
But when I run the code, I have the following exception Confused | :confused: :
http://www.m5zn.com/newuploads/2015/03/21/jpg//9a5f11556559e6b.jpg
Anyone help please :(
推荐答案
您应该尝试在 [] $之间包装名称c $ c>然后再次尝试。例如, [ApplicationName]
然后尝试。如果不起作用,请更改数据库表中的列名并尝试别的。
You should try wrapping the name between[]
and then trying it again. Such as,[ApplicationName]
and then try. If doesn't work, please change the column's name inside your database table and try something else.
这篇关于Membership.CreateUser()被赋予例外!!的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!