Click here to Skip to main content
15,911,360 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralGDI+ Why does the trick fail, one Rect to two Points Pin
followait21-Dec-07 6:16
followait21-Dec-07 6:16 
GeneralRe: GDI+ Why does the trick fail, one Rect to two Points Pin
Mark Salsbery21-Dec-07 6:26
Mark Salsbery21-Dec-07 6:26 
GeneralRe: GDI+ Why does the trick fail, one Rect to two Points Pin
followait21-Dec-07 7:45
followait21-Dec-07 7:45 
GeneralRe: GDI+ Why does the trick fail, one Rect to two Points Pin
Mark Salsbery21-Dec-07 8:48
Mark Salsbery21-Dec-07 8:48 
GeneralGDI+ A transformation from world coordinate to page coordinate makes picture foggy Pin
followait21-Dec-07 6:08
followait21-Dec-07 6:08 
GeneralRe: GDI+ A transformation from world coordinate to page coordinate makes picture foggy Pin
CPallini21-Dec-07 6:49
mveCPallini21-Dec-07 6:49 
GeneralGetUserName() return "SYSTEM" FOR SYSTEM PROCESS Pin
vicky0000021-Dec-07 4:25
vicky0000021-Dec-07 4:25 
GeneralRe: GetUserName() return "SYSTEM" FOR SYSTEM PROCESS Pin
myshketer21-Dec-07 5:05
myshketer21-Dec-07 5:05 
GeneralRe: GetUserName() return "SYSTEM" FOR SYSTEM PROCESS Pin
vicky0000021-Dec-07 6:02
vicky0000021-Dec-07 6:02 
GeneralRe: GetUserName() return "SYSTEM" FOR SYSTEM PROCESS Pin
Mark Salsbery21-Dec-07 6:35
Mark Salsbery21-Dec-07 6:35 
GeneralRe: GetUserName() return "SYSTEM" FOR SYSTEM PROCESS Pin
Mark Salsbery21-Dec-07 7:44
Mark Salsbery21-Dec-07 7:44 
GeneralExtra bytes between struct elements spoiling match between structs and binary file formats: cure found Pin
Anthony Appleyard21-Dec-07 1:59
Anthony Appleyard21-Dec-07 1:59 
GeneralRe: Extra bytes between struct elements spoiling match between structs and binary file formats: cure found Pin
Matthew Faithfull21-Dec-07 2:13
Matthew Faithfull21-Dec-07 2:13 
JokeIndeed... Pin
CPallini21-Dec-07 2:52
mveCPallini21-Dec-07 2:52 
JokeRe: Indeed... Pin
Matthew Faithfull21-Dec-07 3:04
Matthew Faithfull21-Dec-07 3:04 
GeneralRe: Indeed... Pin
CPallini21-Dec-07 3:15
mveCPallini21-Dec-07 3:15 
GeneralRe: Extra bytes between struct elements spoiling match between structs and binary file formats: cure found Pin
Mark Salsbery21-Dec-07 8:14
Mark Salsbery21-Dec-07 8:14 
Questionis such exception handling approach good? Pin
George_George21-Dec-07 1:42
George_George21-Dec-07 1:42 
AnswerRe: is such exception handling approach good? Pin
Matthew Faithfull21-Dec-07 2:05
Matthew Faithfull21-Dec-07 2:05 
QuestionThread using COleDispatchDriver always causes exception on second execution Pin
Streifenhoernchen21-Dec-07 1:42
Streifenhoernchen21-Dec-07 1:42 
GeneralRe: Thread using COleDispatchDriver always causes exception on second execution Pin
Nathan Holt at EMOM21-Dec-07 7:43
Nathan Holt at EMOM21-Dec-07 7:43 
Member 4760200 wrote:
In general, what the thread does is: Creating and sending an e-mail containing a file attachment using an Outlook or Lotus Notes client (if installed on the system).
Running the thread once always works fine, and it terminates correctly. However, when i try to run it for a second time, it throws an exception in MFC42.DLL, unfortunately not always at the same code line, but more or less randomly, esp. during manual debugging:


I would look up the MFC implementation of the send mail command in CDocument, and adapt the code to my purposes, rather than sending it through Outlook or Lotus Notes. If I did need to do it that way, one of the first questions I'd ask is "What exception is being thrown?" Also, in general returning 1 is not adequate for handling unknown exceptions. Terminating the whole program is more reasonable. Finally, the random nature of the exception sounds like a race condition, and since it doesn't go away when you debug, I would guess that you are calling functions that are intended to be called from only one thread for the duration of the process. I'm sorry I can't be more helpful.

Nathan
GeneralSubclassing (using MFC) a wndow under explorer process Pin
Nishad S21-Dec-07 1:38
Nishad S21-Dec-07 1:38 
QuestionReference are always lvalue? Pin
George_George21-Dec-07 1:11
George_George21-Dec-07 1:11 
AnswerRe: Reference are always lvalue? Pin
Budric B.21-Dec-07 5:09
Budric B.21-Dec-07 5:09 
GeneralRe: Reference are always lvalue? Pin
George_George21-Dec-07 19:16
George_George21-Dec-07 19:16 

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.