| Author |
Displaying Errors on Ajax return function.
|
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
Maybe I am doing something wrong, but... Let's say I have the following (psuedo code) In someCallBackFunction, if there is a javascript error, the browser never reports it. Very hard to debug. I've tried overriding the window.onerror but I don't believe that is even being thrown. So how would I go about dealing with this? Thanks.
|
 |
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15357
|
|
How do you know an error occurs if it is not being reported? That is the answer I want to know. lol Eric
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
Because the page just stops. I can put alert messages in the function and move them until they don't display. Then I kind of know where the error is. For example: The last alert never happens. But the browser doesn't report the problem with the variable c. [ May 02, 2006: Message edited by: Gregg Bolinger ]
|
 |
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15357
|
|
With all of my fucntion I use try catch statements which are logged to my server. Here is a basic exacmple that shows you basic functionality with try catch See if that catches it. Eric
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
|
That worked! Thanks Eric.
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
|
Ok, so I have e.message, e.description, e.name... I am trying to find the other methods available, if any. Google hasn't turned up anything yet. Anyone know where I would find these defined?
|
 |
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15357
|
|
that is all you are going to get. Loop through the properties of e to see it by using for in Eric
|
 |
 |
|
|
subject: Displaying Errors on Ajax return function.
|
|
|