User-Friendly Exception Handling

I just posted a new article on Code Project, User Friendly Exception Handling. This is a set of classes that deal with unhandled and handled exceptions through a consistent UI, as presented in Alan Cooper’s great book, About Face: The Essentials of User Interface Design.

Anyway, at the time of the unhandled exception, here’s what you get for free:

  • Display an automatic, Cooper-Approved(tm) exception interface
  • Capture a screenshot of the user’s desktop
  • Build a string containing comprehensive diagnostic information
  • Notify the developers via SMTP e-mail, and attach the screenshot
  • Write an event to the event log
  • Write a plain-text exception log in the application folder

I have used the hell out of this code and it works like gangbusters. There’s nothing like an extremely tight loop between developers and exceptions to facilitate quick, responsive fixes to broken code. And since we have it set up to email every team member for every Unhandled Exception – it’s a therapeutic form of punishment, too!

Also, if anyone is interested in those animated GIF screenshots – I had been looking for a simple tool to do this for literally years – it’s the archaic 1997 version of GifgIfgiF. Extremely old-school, but it still works great and generates very tiny, ultra-compatible animated Gifs. Of course you’ll want to turn off all the crazy XP theming and revert to 256-color friendly Win2k style forms before you generate these kinds of Gif animations, too.

Download the VS.NET 2003 solution.

Related posts

Because Reading is Fundamental

Because Reading is Fundamental

Most discussions show a bit of information next to each user: What message does this send? * The only number you can control printed next to your name is post count. * Everyone who reads this will see your current post count. * The more you post, the bigger that number next to

By Jeff Atwood ·
Comments

The “Just In Time” Theory of User Behavior

I’ve long believed that the design of your software has a profound impact on how users behave within your software. But there are two sides to this story: * Encouraging the “right” things by making those things intentionally easy to do. * Discouraging the “wrong” things by making those things intentionally

By Jeff Atwood ·
Comments

For a Bit of Colored Ribbon

For the last year or so, I've been getting these two page energy assessment reports in the mail from Pacific Gas & Electric, our California utility company, comparing our household's energy use to those of the houses around us. Here's the relevant excerpts from

By Jeff Atwood ·
Comments

Are You a Digital Sharecropper?

Will Work for Praise: The Web's Free-Labor Economy [https://www.bloomberg.com/news/articles/2008-12-28/will-work-for-praise-the-webs-free-labor-economybusinessweek-business-news-stock-market-and-financial-advice] describes how many of today's websites are built by the users themselves: > It's dawn at a Los Angeles apartment overlooking the Hollywood Hills. Laura Sweet, an advertising

By Jeff Atwood ·
Comments

Recent Posts

Let's Talk About The American Dream

Let's Talk About The American Dream

A few months ago I wrote about what it means to stay gold — to hold on to the best parts of ourselves, our communities, and the American Dream itself. But staying gold isn’t passive. It takes work. It takes action. It takes hard conversations that ask us to confront

By Jeff Atwood ·
Comments
Stay Gold, America

Stay Gold, America

We are at an unprecedented point in American history, and I'm concerned we may lose sight of the American Dream.

By Jeff Atwood ·
Comments
The Great Filter Comes For Us All

The Great Filter Comes For Us All

With a 13 billion year head start on evolution, why haven’t any other forms of life in the universe contacted us by now? (Arrival is a fantastic movie. Watch it, but don’t stop there – read the Story of Your Life novella it was based on for so much

By Jeff Atwood ·
Comments
I’m feeling unlucky... 🎲   See All Posts