0

我一直在尝试修复这个错误几个小时,我尝试了我能做的一切,但没有成功。我对 C# 很陌生。我想知道是否有人可以帮助我确定如何开始解决此错误?

错误信息:

Could not load type 'Inventory1.Global'.    W:\admin.fctl.ucf.edu\inventory\Global.asax 1   

Global.asax 内容:

<%@ Application Codebehind="Global.asax.cs" Inherits="Inventory1.Global" Language="C#"%>

Global.asax.cs 内容:

using System;
using System.Collections;
using System.ComponentModel;
using System.Web;
using System.Web.SessionState;

namespace Inventory1 
{
    /// <summary>
    /// Summary description for Global.
    /// </summary>
    public class Global : System.Web.HttpApplication
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        public Global()
        {
            InitializeComponent();
        }   

        protected void Application_Start(Object sender, EventArgs e)
        {

        }

        protected void Session_Start(Object sender, EventArgs e)
        {

        }

        protected void Application_BeginRequest(Object sender, EventArgs e)
        {

        }

        protected void Application_EndRequest(Object sender, EventArgs e)
        {

        }

        protected void Application_AuthenticateRequest(Object sender, EventArgs e)
        {

        }

        protected void Application_Error(Object sender, EventArgs e)
        {

        }

        protected void Session_End(Object sender, EventArgs e)
        {

        }

        protected void Application_End(Object sender, EventArgs e)
        {

        }

        #region Web Form Designer generated code
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {    
            this.components = new System.ComponentModel.Container();
        }
        #endregion
    }
}
4

1 回答 1

0

该代码适用于我的机器。检查以确保 Dll 存在于 /bin 目录中。此外,请确保 bin 和 Global.asax 文件存在于应用程序的根目录中。服务器级别的某个人很可能更改了 IIS 中的某些内容。

于 2013-02-27T17:43:43.773 回答