error-handling

How do I pass error information through an HTTP Request in Flex 3?

My Flex3 application must display meaningful application-level error messages from the server. This article article says that Flash has severe limitations on receiving error info, whether as status codes, response body, or response headers as described. I can use any of these from my servlet. But apparently none are accessible! But the...

Struts/Spring with Tiles error-page

I'm still a newbie, and I'm not sure how else to implement custom error pages. I'm using tiles, and I believe this project has the struts2 and spring framework mangled together. I did the basic stuff in my web.xml: <error-page> <error-code>404</error-code> <location>/WEB-INF/jsps/404error.jsp</location> </error-page> Works p...

What is best practice to handle all Exceptions in WPF application?

HiIs there any way to handle all Errors Exceptions and crashes in WPF application? I know about DispatcherUnhandledException, but it handles only exceptions in UI thread, isn't it? Is there a way to catch and log all exceptions in other threads? and binding errors too? How do you implement this kind of requirement in your enterprice syst...

How can I create an error handling page in ICEfaces (with Facelets)?

I need a little help creating a catch-all error handling page in my ICEfaces application. I'd like to present a user-friendly message along with an exception stack trace. I can redirect to an error page using the following directive in web.xml: <error-page> <error-code>500</error-code> <location>/error.xhtml</location> </error-page...

AJAX Error: The data necessary to complete this operation is unavailable

Every once and a while I get this error in IE when making an AJAX request to a handler that returns a small response of type text/plain. It seems that this error will start happening, occur a few times, and then it will stop. Very annoying. I am using the latest jQuery library. The error throws in the complete() function when I try t...

Using a global (dumb) error page for all ASP.NET MVC errors?

I've set up and configured ELMAH to log all of my errors on an ASP.NET MVC project I'm working on. It will be used by a small group of users who don't need to know too much so whenever there is any sort of error (404, InvalidOperation, Y2K... anything!) I just want to show them a generic default error view with instructions to call our h...

How can I change the Apache ErrorDocument from a Perl handler?

Is there a way to have your PerlAuthenHandler, PerlAuthzHandler, or even your PerlHandler change the error document for a request? Example: When the user goes to a specific page and gets an error, I want to have a subroutine choose what error document errors are thrown to. ...

how to handle SQL Agent job error?

Hello everyone, I am writing a SQL Agent Job to remove rows from Table 1 and Table 2 once a day. The step of the SQL Agent job is -- delete some specific records from Table1, then delete some specific records from Table 2. My question is, How to record the error during SQL Agent? Any logs/events we could use? (so that we could see in...

Is it kosher to assign to $! in Perl?

Is it OK to assign to $! on an error in Perl? E.g., if( ! (-e $inputfile)) { $! = "Input file $inputfile appears to be non-existent\n"; return undef; } This way I can handle all errors at the top-level. Thanks. ...

Correct Structure to check for Errors using NSError

I'm coding up various routines and I'm trying my best to keep it neat and refactored. Methods I'm creating are starting to look similar to this code: -(IBAction)buttonPress:(id)sender { // Create Document Shopping List with this document [self doSomething:&error]; if(error) { [NSApp presentError:&error]; re...

How can I tell what module my code is executing in?

For a very long time, when I have an error handler I make it report what Project, Module, and Procedure the error was thrown in. I have always accomplished this by simply storing their name via constants. I know that in a Class you get the name programmatically with TypeName(Me), but obviously that only gets me one out of three pieces o...

error handling for AJAX div

Hello. I've been using a very helpful AJAX-based script called AJAXTwits to load multiple Twitter timelines for a sports team into a div. The nice thing about the script is that it (1) combines multiple timelines into one chronological timeline and (2) caches the xml for faster loading. Every so often, though, Twitter's feeds go down,...

formencode invalid return type

if an exception occurs in form encode then what will be the return type?? suppose if(request.POST): formvalidate = ValidationRule() try: new = formvalidate.to_python(request.POST) data = Users1( n_date = new['n_date'], heading = new['heading'], desc = new['desc'], link...

The "right" way to do stored procedure parameter validation

I have a stored procedure that does some parameter validation and should fail and stop execution if the parameter is not valid. My first approach for error checking looked like this: create proc spBaz ( @fooInt int = 0, @fooString varchar(10) = null, @barInt int = 0, @barString varchar(10) = null ) as begin if (@fooInt = 0 an...

How can I pass JavaScript errors from an action to my view?

I have 2 actions, one for GET and the other handles POST requests. Although I have validation on the client side, there are some things I check for on the server-side also (in my action method). In the POST action, when I find errors etc. that I want to report back to the UI, what options do I have to send back messages/errors to the c...

IE printing out source code at random (seems very nondeterministic)

Hey. the busted website is: www.mgxvideo.com/mgxcopy-alpha-3, and the specific error that I'm getting is the thing where IE prints out all my source code. As far as I can tell, the error is appearing at random in IE6, 7, and 8, but it's a commonly occuring error. I'm looking for explanations, debugging tools, fixes. Anything is appreci...

How do you supress errors to a method call in C#?

I'm looking for an "elegant" way to supress when calling a method. I think try { CallToMethodThatMayFail(3); } catch {} is way too verbose. Is there some syntactic sugar I can use to say "I don't really care if this method fails"? I want to call the method and continue execution regardless of what happens with the method. BTW, mov...

Log4Net, ThreadContext, and Global.asax

I am working on a Log4Net configuration that will log all unhandled exceptions. I need certain properties, based on user, to be added to each log entry. I have set this up successfully in the following manner in my Application_Error event. Here is my complete global.asax Imports log4net Imports log4net.Config Public Class Global...

How can I return both an error string and error code to VB6 from an ATL activex control?

I'm trying to return a detailed error to VB6 using CComCoClass::Error, but it seems I can only return an error code /or/ a message - but not both. return Error(_T("Not connected"), __uuidof(IMyInterface), HRESULT_FROM_WIN32(ERROR_CONNECTION_INVALID)); results in a generic "Method 'Request' of object 'IMyInterface' failed" error messag...

How can i make errorpages in jsf ?

Everytime something gets wrong .. i got to see this. How can i make a simple Errorpage with stacktrace in jsf ? ...