Asp.net aspxerrorpath=\errorpage.aspx追加到url的查询字符串

Asp.net aspxerrorpath=\errorpage.aspx追加到url的查询字符串,asp.net,Asp.net,我在web.config文件中定义了自定义错误 <customErrors mode="On" defaultRedirect="ErrorPage.aspx"> <error statusCode="404" redirect="ErrorPage.aspx"/> </customErrors> 每当它重定向到错误页面aspxerrorpath查询字符串追加时,我得到 “/”应用程序运行时错误中的服务器错误 而不是错误页面 任何人都可以给

我在web.config文件中定义了自定义错误

<customErrors mode="On" defaultRedirect="ErrorPage.aspx">
  <error statusCode="404" redirect="ErrorPage.aspx"/>     
</customErrors>

每当它重定向到错误页面aspxerrorpath查询字符串追加时,我得到

“/”应用程序运行时错误中的服务器错误

而不是错误页面

任何人都可以给我提供建议,如何避免查询字符串被追加?

url看起来像这样“可能的url副本看起来像这样”可能的url副本