Ask a Question related to ASP Database, Design and Development.
-
Eric Bobo #1
Error Object/GetLastError
Can someone clue me in as to why the following code for Error Object
does not work. The errors get caught, but no information exists in the
Error object fields. If I use the old err.desciption, etc I can see
values and information. What am I doing wrong?
***********************************
Dim objASPError
function junk
On Error Resume Next
'database code here
'update database
RSPayPrem.update
If Err.number > 0 Then
Set objASPError = Server.GetLastError
RSPayPrem.Close
Set RSPayPrem = Nothing
errmessage = "There was a critical error..."
'call function to display error message on error page
'passing error object fields
'(the next line displays on 1 line in code)
'(Display Error is a function with parms)
DisplayError
errmessage,objASPError.ASPCode,objASPError.Number, objASPError.Source,objASPError.Category,objASPErro r.File,objASPError.Line,objASPError.Column,objASPE rror.Description,objASPError.ASPDescription
End If
function end
************************************************** ********
Thanks
Eric
Eric Bobo Guest
-
Strange error from: Dim myState As Object() = CType(savedState, Object())
Every book and every website I've seen that talks about how to save state for child controls in a composite webcontrol says to do something like... -
Mysterious Error: Object reference not set to an instance of an object
Hi There! I'm having a mysterious error right after I login using Forms Authentication in my ASP.NET app. Below is the error... Exception... -
Getting GetLastError=0x00000485 when tryin to install AspSmartUpload
Hello dudes, I'm getting this error that's driving me mad :-/ LoadLibrary("aspSmartUpload") failed GetLastError returns 0x00000485 My Os is... -
HELP! Error Loading ASPX : Object Reference not set to an instance object
Hello, When i run my aspx i get this weird error: System.NullReferenceException: Object reference not set to an instance of an object. at... -
Server.GetLastError() return null
Try using the Application_Error() event in Global.asax. The context of the error will be available here. Your application is handling the error,...



Reply With Quote

