Returns the previous exception.
'Usage Dim instance As HttpServerUtility Dim returnValue As Exception returnValue = instance.GetLastError() 'Declaration Public Function GetLastError As Exception
The following example prints a description of the application's last error to the HTTP output stream. It prints "No Errors" if no errors have been encountered.
Dim LastError As Exception Dim ErrMessage As String LastError = Server.GetLastError() If Not LastError Is Nothing Then ErrMessage = LastError.Message Else ErrMessage = "No Errors" End If Response.Write("Last Error = " & ErrMessage)
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98