Click here to Skip to main content
16,005,060 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralGDI+ problem Pin
Alex Boyce5-May-03 9:37
Alex Boyce5-May-03 9:37 
GeneralError handling Pin
Jerome Conus5-May-03 8:53
Jerome Conus5-May-03 8:53 
GeneralRe: Error handling Pin
valikac5-May-03 9:09
valikac5-May-03 9:09 
GeneralRe: Error handling Pin
Joaquín M López Muñoz5-May-03 9:10
Joaquín M López Muñoz5-May-03 9:10 
GeneralRe: Error handling Pin
Tim Smith5-May-03 9:30
Tim Smith5-May-03 9:30 
GeneralRe: Error handling Pin
Tim Smith5-May-03 9:23
Tim Smith5-May-03 9:23 
GeneralRe: Error handling Pin
Ryan Binns6-May-03 2:06
Ryan Binns6-May-03 2:06 
GeneralRe: Error handling Pin
David Chamberlain5-May-03 9:29
David Chamberlain5-May-03 9:29 
I've had to deal with something similar recently, and it is very hard to find any relevant materials. While many sources will tell you how to implement exception handling, your questions are similar to mine, and the answers are not found in how to structure exception handling or use return codes.

An unremembered source provided a very intriquing question in response to all of my questions, and the question dealt with the impact to the user. Have you ever used a word processing program that after you typed up your letter you went to print and the application came back with "The application encountered an error and will have to close." That's great, except what happened to my letter? It appears to be gone. DAMN!!!!

So, much of error recovery strategy can be focused on what happens to the user (or to other applications if this is an embedded app or something such). Will a memory error cause something fatal that will be a real inconvenience to the user? Enough so that he may not ever want to use this app again? Will a file error cause his work to be lost? Will invalid input cause something else to go wrong? What are the sources of errors that will hamper the user?

When the answers are determined by an impact to the user of your app, then error recovery starts to become clearer. If, at all costs, you value the user and want to isolate him from any irritation caused by something in your app, then whether you use exceptions or return codes becomes an implementation detail of a larger topic.

Good luck,
Dave

"You can say that again." -- Dept. of Redundancy Dept.
GeneralCEdit problem Pin
Jonas Ullberg5-May-03 8:35
Jonas Ullberg5-May-03 8:35 
GeneralRe: CEdit problem Pin
David Crow5-May-03 8:39
David Crow5-May-03 8:39 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 8:42
Jonas Ullberg5-May-03 8:42 
GeneralRe: CEdit problem Pin
jhaga5-May-03 8:47
professionaljhaga5-May-03 8:47 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 8:52
Jonas Ullberg5-May-03 8:52 
GeneralRe: CEdit problem Pin
jhaga5-May-03 8:55
professionaljhaga5-May-03 8:55 
GeneralRe: CEdit problem Pin
David Crow5-May-03 8:50
David Crow5-May-03 8:50 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 9:05
Jonas Ullberg5-May-03 9:05 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 9:07
Jonas Ullberg5-May-03 9:07 
GeneralRe: CEdit problem Pin
Hari Krishnan (Noida)5-May-03 21:38
Hari Krishnan (Noida)5-May-03 21:38 
GeneralRe: CEdit problem Pin
jhaga5-May-03 9:09
professionaljhaga5-May-03 9:09 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 9:26
Jonas Ullberg5-May-03 9:26 
GeneralRe: CEdit problem Pin
Toni785-May-03 9:24
Toni785-May-03 9:24 
GeneralRe: CEdit problem Pin
jhaga5-May-03 9:40
professionaljhaga5-May-03 9:40 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 9:43
Jonas Ullberg5-May-03 9:43 
GeneralRe: CEdit problem Pin
Jonas Ullberg5-May-03 9:54
Jonas Ullberg5-May-03 9:54 
GeneralRe: CEdit problem Pin
Toni785-May-03 9:53
Toni785-May-03 9:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.