Asp.net-服务器错误 [英] Asp.net - Server Error

查看:80
本文介绍了Asp.net-服务器错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我正在Asp.net应用程序上.在我的应用程序中,我已将所有aspx页面存储在文件夹C:\ ProjectName \ Admin \ Cube.aspx
但是当我尝试访问该文件夹中不存在的任何页面时
例如C:\ ProjectName \ Admin \ Cube111.aspx
它给了我以下错误:

''/''应用程序中的服务器错误.
找不到资源.
说明:HTTP404.您正在寻找的资源(或其依赖项之一)可能已被删除,名称更改或暂时不可用.请查看以下URL,并确保其拼写正确.

要求的网址:/Admin/Cubes1.aspx
-------------------------------------------------- ------------------------------
版本信息:Microsoft .NET Framework版本:2.0.50727.3607; ASP.NET版本:2.0.50727.3614


我想显示一些错误消息或重定向到另一个标准错误消息,而不是此错误消息.

请帮忙.

提前谢谢..

问候,
Swati

Hello All,

I am working on Asp.net application. In my application, i have stored all the aspx page in folder C:\ProjectName\Admin\Cube.aspx
But when i try to access any page that doest exists in the folder
e.g C:\ProjectName\Admin\Cube111.aspx
It gives me following error:

Server Error in ''/'' Application.
The resource cannot be found.
Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.

Requested URL: /Admin/Cubes1.aspx
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.3607; ASP.NET Version:2.0.50727.3614


Instead of this error msg, i want to display some error msg or redirect to another standard error msg.

Please help.

Thanks in advance..

Regards,
Swati

推荐答案

处理错误的方法很少.看看几个:
ASP.NET中的Web应用程序错误处理 [ Smart404:在ASP.NET中巧妙地处理404 [ ASP.NET中的错误处理 [
There are few ways to handle the error. Have a look at few:
Web Application Error Handling in ASP.NET[^]
Smart404: Handle 404 smartly in ASP.NET [^]
Error Handling in ASP.NET[^]
They should resolve it for you!


这篇关于Asp.net-服务器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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