热搜词
发表于 2013-8-30 09:04:29 | 显示全部楼层 |阅读模式
Server Error in '/' Application.
Object reference not set to an instance of an object. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:

[No relevant source lines]

Source File: c:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\52fd62ac\85f99b73\App_Web_pwvd3og4.1.cs    Line: 0

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]   Web.UI.BasePage..ctor() in F:\2013 年 开发的系统\宿城区老干部局网站\Progect\Web.UI\BasePage.cs:14   Web.Index..ctor() +29   ASP.index_aspx..ctor() in c:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\52fd62ac\85f99b73\App_Web_pwvd3og4.1.cs:0   __ASP.FastObjectFactory_app_web_pwvd3og4.Create_ASP_index_aspx() in c:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\52fd62ac\85f99b73\App_Web_pwvd3og4.10.cs:0   System.Web.Compilation.BuildResultCompiledType.CreateInstance() +32   System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp) +109   System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) +31   System.Web.UI.PageHandlerFactory.System.Web.IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) +40   System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig) +167   System.Web.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +128   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +184
全部评论1
灰儿 发表于 2013-8-30 09:05:39 | 显示全部楼层
请确保在 aspx中的页面指令 Inherits属性与aspx.cs中的类一致
HTML code
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="CheckBoxListDemo.aspx.cs" Inherits="CheckBoxListDemo" %>
回复

使用道具 举报

回复
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|手机版|小黑屋|管理员之家 ( 苏ICP备2023053177号-2 )

GMT+8, 2024-11-25 07:34 , Processed in 0.156437 second(s), 22 queries .

Powered by Discuz! X3.5

Cpoyright © 2001-2024 Discuz! Team