好得很程序员自学网

<tfoot draggable='sEl'></tfoot>

可以让程序告诉我详细的页面错误和数据库连接

NEWSZW_HZH_BEGIN-->

<%
 If Err.Number <> 0 Then
  ' 错误处理 .
       Response.Clear
       ' 清除缓冲区 .
 

      Select Case Err.Number
            ' 根据不同错误分处理 .
    Case ""

' 指定错误类型 : 此处填加我们指定的错误处理代码 .
      Case Else

  ' 一般错误 .

            If IsObject(objConnection) Then
                  If objConnection.Errors.Count > 0 Then %>
<B> 撼雪喷云之数据连接对象错误报告 </B>
<% For intLoop = 0 To objConnection.Errors.Count - 1 %>
错误号 : <%= objConnection.Errors(intLoop).Number %><BR>
错误描述 : <%= objConnection.Errors(intLoop).Description %><BR>
错误源 : <%= objConnection.Errors(intLoop).Source %><BR>
SQL 状态 : <%= objConnection.Errors(intLoop).SQLState %><BR>
本地错误 : <%= objConnection.Errors(intLoop).NativeError %><P>
<% Next
   End If
   End If
   If Err.Number <> 0 Then %>

<B> 撼雪喷云之页面错误报告 </B><BR>
错误号 :<%= Err.Number %><BR>
错误描述 :<%= Err.Description %><BR>
错误源 :<%= Err.Source %><BR>
错误发生行 :<%= Err.Line %><P>
<%
            End If
      End Select
End If
%>

[1]

NEWSZW_HZH_END-->

查看更多关于可以让程序告诉我详细的页面错误和数据库连接的详细内容...

  阅读:42次