asp网站报错“ An error occurred on the server when processing the URL. ”

 访问网页发生“ An error occurred on the server when processing the URL. ”,

访问现象是:ID大于32767时就会报错,小于32767无问题

 

 

小于32767的情况:

 

 

参照下面参考文章,

设置方法一: 

以管理员身份运行CMD,将目录定位到%windir%\system32\inetsrv\,然后执行

appcmd set config -section:asp -scriptErrorSentToBrowser:true

含义:将ASP内部错误发送到浏览器,以暴露问题定位。

再次访问报错:

Microsoft VBScript 运行时错误 错误 '800a0006' 溢出: 'CInt'

检查文件 Sitepage.asp发现使用了函数,而字符串转化为整数 asp: cint()--注意只能转换短整数值的范围必须在-32768与32767之间;

长整数应用clng();也就是说,此处当ID大于32767时,应该替换函数cint()为clng()。

  保存后发现成功解决。

参考:

1.IIS出现An error occurred on the server when processing the URL. 

2.Microsoft VBScript 运行时错误 错误 '800a0006'

3.Provider 错误 '80004005' 未指定的错误 的最终解决方法

posted @ 2022-09-08 15:25  coderjim  阅读(405)  评论(0)    收藏  举报

更多知识请点击——

www.7017online.xyz