发布MVC程序的时候经常遇到这种情况,每次都要搞好久才找到问题。最终找到解决办法:

报500错误大部分的情况还是程序存在异常,但全部被MVC错误拦截成了友好提示,

只要在Web.config下添加一行配置即可

<system.web>
\\其他配置代码
\\其他配置代码
\\其他配置代码 在system.web节点下添加此代码可现实详细错误信息,解决问题后设置为On 继续提示友好信息
<customErrors mode="Off" />
</system.web>

MVC 本地运行可以发布到IIS 报Sorry, an error occurred while processing your request.解决方案的更多相关文章

  1. apache include 文件包含引用的方法 报错 [an error occurred while processing this directive]

    今天遇到在某平台买的虚拟主机服务器不支持    下面的这样的写法 <!--#Include file="/templets/2013new/header.htm"--> ...

  2. appium报错:An unknown server-side error occurred while processing the command. Original error: Could not proxy command to remote server. Original error: Error: read ECONNRESET

    Appium Desktop版本:1.9.0 xcode版本:9.4.1 测试机:iPhone7  11.3系统 问题描述:在xcode上的produc的text运行是可以将WebDriverAgen ...

  3. eclipse 中离线安装activiti插件,报错“An error occurred while collecting items to be installed session context was:(...”

    eclipse 中离线安装activiti插件,报错“An error occurred while collecting items to be installed session context ...

  4. SOAPtest报错:error occurred during initialization of vm解决方法

    参考:http://forums.parasoft.com/index.php?act=ST&f=36&t=614 安装SOAPtest报错:error occurred during ...

  5. 踩坑系列《三》 java -version 报错出现Error occurred during initialization of VM java/lang/NoClassDefFoundError:

    之前导入一个项目,因为该项目Spring版本过低,只能适用于1.7版本,装了jdk1.7版本.安装配置好后,打开cmd窗口,执行 java -version 指令发现没像正常一样显示版本信息,而是报了 ...

  6. python appium自动化报“Encountered internal error running command: UnknownError: An unknown server-side error occurred while processing the command. Original error: Could not proxy command to remote server

    运行app自动化代码时报"Encountered internal error running command: UnknownError: An unknown server-side e ...

  7. 本地运行aws lambda credential 配置 (missing credential config error)

    参照这篇文章 http://docs.aws.amazon.com/sdk-for-javascript/v2/developer-guide/loading-node-credentials-sha ...

  8. Windows本地运行调试Spark或Hadoop程序失败:ERROR util.Shell: Failed to locate the winutils binary in the hadoop binary path

    报错内容 ERROR util.Shell: Failed to locate the winutils binary in the hadoop binary path java.io.IOExce ...

  9. NETCore项目报错 An error occurred while starting the application

    在发布到IIS的webApi项目中,运行时报出以上错误, 解决方法: 1.打开发布目录文件夹,找到web.config文件 2.打开web.config找到stdoutLogEnabled=" ...

随机推荐

  1. 关于malloc的一些想法

    之前一段时间翻阅过一些内存分配的资料,这次终于能将其整理记录下来了. c标准库里有两个耳熟能详的函数,用于对堆空间的内存进行分配和释放,它们分别是: malloc.负责分配一个指定大小的一块内存给调用 ...

  2. React 学习资源汇总(最全的 React 学习资料)

    http://www.360doc.com/content/16/1108/10/17722897_604827790.shtml

  3. H5离线存储

    如何使用 首先,我们建立一个html文件,类似这样: <!DOCTYPE html> <html lang="en" manifest="manifes ...

  4. [HTML/HTML5]7 使用列表

    7.1  在Web页面中使用有序.无序.定义列表 (1)有序列表 有序列表中的每一个列表项之前,都以一个数字或字母作为编号. <ol> <li>树莓</li> &l ...

  5. 设置默认python模块源

    可以在Linux编辑~/.pip/pip.conf或者在Windows下编辑%HOME%\pip\pip.ini,内容如下:[global]index-url = http://pypi.douban ...

  6. 用 highlight.js 为文章中的代码添加语法高亮

    来源:http://www.ghostchina.com/adding-syntax-highlighting-to-ghost-using-highlight-js/ --------------- ...

  7. Asp.net MVC过滤器的使用

    当我们网站开发到这里的时候,我们虽然已经实现了用户登录信息,用户不经过登录信息,比如:http://localhost:6941/UserInfo/Index如果我这样访问的话,他是可以进行操作的,所 ...

  8. T4模板批量生成代码

    大家通过比对下,就应该知道怎么玩. T4代码 <#@ template debug="false" hostspecific="true" languag ...

  9. localStorage存的值如果有true,false,需要注意了。

    把一个全局变量存到localStorage里面 isSupport是 true  false; window.localStorage && window.localStorage.s ...

  10. PDF 补丁丁 0.5.0.2713 发布(替换字库功能修正字符宽度问题)

    新版本替换字库后,采用新字库的字符宽度.基本上可以满足一般的字库替换需求.请下载新版本测试.