无法加载类型'HDI.AspNet.Membership.HDIMembershipProvider'。 [英] Could not load type 'HDI.AspNet.Membership.HDIMembershipProvider'.

查看:85
本文介绍了无法加载类型'HDI.AspNet.Membership.HDIMembershipProvider'。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hii,



以下是我的web.config文件部分



 <   connectionStrings  >  
< add < span class =code-attribute> name = DefaultConnection providerName = System.Data.SqlClient connectionString = 数据源=(LocalDb)\ v11.0;初始目录= aspnet-AutoSpareParts-20141021232459;集成安全性= SSPI; AttachDBFilename = | DataDirectory | \ aspnet -AutoSpareParts-201 41021232459.mdf / >
< add name = AutoSparePartsConnection < span class =code-attribute> providerName = System.Data.SqlClient connectionString = 数据源= TORAKAMI\TORAKAMI;初始目录= AutoSpareParts;集成安全性= True / >
< / connectionStrings >







< membership defaultprovider =HDIMembershipProvideruserisonlinetimewindow =15>



< providers>

< ;清除>

< add>

name =HDIMembershipProvider

type =HDI.AspNet.Membership.HDIMembershipProvider
connectionStringName =AutoSparePartsConnection

enablePasswordRetrieval =true

enablePasswordReset =true

requiresQuestionAndAnswer =true

writeExceptionsToEventLog =false/>







但我是得到以下的错误



'/'应用程序中的服务器错误。

配置错误

描述:发生错误在处理为此reque提供服务所需的配置文件期间ST。请查看下面的具体错误详细信息,并相应地修改配置文件。



分析程序错误消息:无法加载类型'HDI.AspNet.Membership.HDIMembershipProvider'。



来源错误:





第38行:< add>

第39行:name =HDIMembershipProvider

第40行:type =HDI.AspNet.Membership.HDIMembershipProvider

第41行:connectionStringName = AutoSparePartsConnection

第42行:enablePasswordRetrieval =true

解决方案

无法找到您的提供商...

 HDI.AspNet.Membership.HDIMembershipProvider 





这就是你应该写的。



如果你的提供者类文件在App_code文件夹中:

 type =   HDI.AspNet.Membership.HDIMembershipProvider 





否则,如果在单独的dll中:

 type =   Namespace.classname,assembly



汇编〜你的dll名字。



你也可以添加对你的dll的引用


Hii ,

Below is my web.config file section

<connectionStrings>
    <add name="DefaultConnection" providerName="System.Data.SqlClient" connectionString="Data Source=(LocalDb)\v11.0;Initial Catalog=aspnet-AutoSpareParts-20141021232459;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\aspnet-AutoSpareParts-20141021232459.mdf" />
    <add name="AutoSparePartsConnection" providerName="System.Data.SqlClient" connectionString="Data Source=TORAKAMI\TORAKAMI;Initial Catalog=AutoSpareParts;Integrated Security=True" />
  </connectionStrings>




<membership defaultprovider="HDIMembershipProvider" userisonlinetimewindow="15">

<providers>
<clear>
<add>
name="HDIMembershipProvider"
type="HDI.AspNet.Membership.HDIMembershipProvider"
connectionStringName="AutoSparePartsConnection"
enablePasswordRetrieval="true"
enablePasswordReset="true"
requiresQuestionAndAnswer="true"
writeExceptionsToEventLog="false" />



But i am getting Below eror

Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Could not load type 'HDI.AspNet.Membership.HDIMembershipProvider'.

Source Error:


Line 38: <add>
Line 39: name="HDIMembershipProvider"
Line 40: type="HDI.AspNet.Membership.HDIMembershipProvider"
Line 41: connectionStringName="AutoSparePartsConnection"
Line 42: enablePasswordRetrieval="true"

解决方案

It is not able to find your provider ...

HDI.AspNet.Membership.HDIMembershipProvider



this is how you should write.

If your provider class file is in App_code folder :

type="HDI.AspNet.Membership.HDIMembershipProvider"



Else if in seperate dll then:

type="Namespace.classname, assembly".


assembly ~ your dll name.

also you add a reference to your dll


这篇关于无法加载类型'HDI.AspNet.Membership.HDIMembershipProvider'。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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