发布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. Hadoop中wordcount程序

    一.测试过程中 输入命令: 首先需要在hadoop集群中添加文件 可以首先进行查看hadoop集群中文件目录 hadoop fs -ls / hadoop fs -ls -R / hadoop fs ...

  2. 【oracle】 oracle学习笔记1--安装与登录

    由于机器配置原因,加上也是自学,所以就没必要安装专业版的oracle,于是就安装的oracle xe版本 下载地址:http://www.oracle.com/technetwork/database ...

  3. Map的五种遍历方法

    package com.jackey.topic; import java.util.ArrayList;import java.util.HashMap;import java.util.Itera ...

  4. 用margin还是padding

    用margin还是用padding这个问题是每个学习CSS进阶时的必经之路. CSS边距属性定义元素周围的空间.通过使用单独的属性,可以对上.右.下.左的外边距进行设置.也可以使用简写的外边距属性同时 ...

  5. cf Gym 101086M ACPC Headquarters : AASTMT (Stairway to Heaven)

    题目: Description standard input/output As most of you know, the Arab Academy for Science and Technolo ...

  6. 为 iTween 指定特定的回调 : onupdate, oncomplete

    问题地址:Specifying a delegate for the value of onupdate in iTween 1.找到 void CallBack 2.修改以下代码: void Cal ...

  7. Tableau10.0学习随记-分组问题

    1.根据官网的练习视频,分组时可多选列,之后使用回形针按钮创建分组,并重新命名即可,截图如下: 2.但在Tableau10中打开练习工作簿练习时,并没有直接显示分组后结果,仅仅是创建了分组的纬度,结果 ...

  8. STM32外部中断初理解

    PA0,PB0...PG0--->EXTI0 PA1,PB1...PG1--->EXTI1 ....... PA15,PB15...PG15--->EXTI15 以上为GPIO和中断 ...

  9. win环境 yii2 框架 overtrue/wechat 包 由 sys_get_temp_dir 引发的 the directory "c:\Windows" is not writable

    vendor\overtrue\wechat\src\Foundation\Application.php registerBase 方法 在初始化属性时 $this['cache'] = funct ...

  10. HDU 1005 Number Sequence

    Number Sequence Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)T ...