ASP ASPError 对象属性
❮ ASPError 对象完整参考
ASPCode
ASPCode 属性返回 IIS 生成的错误代码。
ASPDescription
ASPDescription 属性返回错误的详细描述。
类别
Category 属性返回错误的来源(错误是由 IIS?脚本语言?还是组件生成的?)。
列
Column 属性返回生成错误的 ASP 文件内的列位置。
描述
Description 属性返回错误的简短描述。
文件
File 属性返回生成错误的 ASP 文件的名称。
折线图
Line 属性返回生成错误的 ASP 文件内的行号。
Number
Number 属性返回错误的标准 COM 错误代码。
Source(来源)
Source 属性返回发生错误的行实际的源代码。
语法
ASPError.ASPCode()
ASPError.ASPDescription()
ASPError.Category()
ASPError.Column()
ASPError.Description()
ASPError.File()
ASPError.Line()
ASPError.Number()
ASPError.Source()
示例
<%
dim objErr
set objErr=Server.GetLastError()
response.write("ASPCode=" & objErr.ASPCode)
response.write("<br>")
response.write("ASPDescription=" & objErr.ASPDescription)
response.write("<br>")
response.write("Category=" & objErr.Category)
response.write("<br>")
response.write("Column=" & objErr.Column)
response.write("<br>")
response.write("Description=" & objErr.Description)
response.write("<br>")
response.write("File=" & objErr.File)
response.write("<br>")
response.write("Line=" & objErr.Line)
response.write("<br>")
response.write("Number=" & objErr.Number)
response.write("<br>")
response.write("Source=" & objErr.Source)
%>
❮ ASPError 对象完整参考