开发者

Error trying to read Roles Section from Web.Config

When executing this line:

Dim roleRedirectSection As LoginRedirectByRoleSection = DirectCast(ConfigurationManager.GetSection("loginRedirectByRole"), LoginRedirectByRoleSection)

...I get the following error:

Message: "An error occurred creating the configuration section handler for loginRedirectByRole: Could not load type 'sitename.LoginRedirectByRoleSection'. (W:\Webs\2010\DEV\sitenam开发者_Go百科e\ASP 4.0\web.config line 10)"

<configuration>
    <configSections>
        <section name="loginRedirectByRole" type="journeyeast.LoginRedirectByRoleSection"   allowLocation="true" allowDefinition="Everywhere" />
    </configSections>
    <loginRedirectByRole>
        <roleRedirects>
            <add role="Administrator" url="~/Account/Admin/Default.aspx" />
            <add role="Employee" url="~/Account/Emp/Default.aspx" />
            <add role="Teacher" url="~/Account/Teacher/Default.aspx" />
            <add role="Student" url="~/Account/Student/Default.aspx" />
            <add role="School" url="~/Account/School/Default.aspx" />
        </roleRedirects>


You may need to specify the full type name, including the assembly that journeyeast.LoginRedirectByRoleSection is in.

type="journeyeast.LoginRedirectByRoleSection, assemblyName"
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜