开发者

Need help on following error Could not load type 'AccountWeb.Global'

I am getting following error when i run my pr开发者_如何学Coject error details. Parser Error

Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: Could not load type 'AccountWeb.Global'.

Source Error:

Line 1:  <%@ Application Codebehind="Global.asax.cs" Inherits="AccountWeb.Global" Language="C#" %>


Source File: /global.asax    Line: 1 

Any help is much appericiated.


For anyone who comes to this issue later on - it's worth mentioning that you also need to make sure that your site is being built to the /bin directory. In the case where you have added your own build configuration, for example, you need to go into your site project's properties and make sure the output path is set to /bin.

-m


What's the contents of your Global.asax.cs? The error indicates there's a mismatch, either in namespace or class name, both must match.

So your .cs file must look something like

namespace AccountWeb
{
    public class Global : System.Web.HttpApplication
    {
        ....
    }
}


This issue I was solved by giving right permission of the folder as well as check from IIS.

I was given permission to everyone as I am testing in my local environment. But in publish mode I think we give only permission to ASP.Net user.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜