MCPD 70-518 Exam Ref: Designing and Developing Windows® Applications Using Microsoft® .NET Framework 4
by Tony Northrup and Matthew A. Stoecker
Chapter Summary
Your exception-handling strategy should catch the most specific error possible, but only when your application can resolve the problem or add useful troubleshooting information to the exception. If you catch an exception and cannot resolve it, rethrow the exception. If you must create a custom exception class, mark it as serializable, make the class accessible to other developers, and provide overloaded constructors. If you need to log more information than is captured in the event log for unhandled exceptions, or if you want to display a friendly error message to users, you can catch DispatcherUnhandledException and set e.Handled to False.
Black box testing functions without having any information about an application’s inner workings. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access