Click here to Skip to main content
15,891,136 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionDigital Library system, Help needed Pin
ShayanTanwir7-May-12 13:32
ShayanTanwir7-May-12 13:32 
AnswerRe: Digital Library system, Help needed Pin
Chris Losinger7-May-12 13:35
professionalChris Losinger7-May-12 13:35 
Questiontry and catch, not sure how to handle catch Pin
jkirkerx7-May-12 10:34
professionaljkirkerx7-May-12 10:34 
AnswerRe: try and catch, not sure how to handle catch Pin
Chuck O'Toole7-May-12 10:45
Chuck O'Toole7-May-12 10:45 
GeneralRe: try and catch, not sure how to handle catch Pin
jkirkerx7-May-12 10:50
professionaljkirkerx7-May-12 10:50 
AnswerRe: try and catch, not sure how to handle catch Pin
Chuck O'Toole7-May-12 12:13
Chuck O'Toole7-May-12 12:13 
GeneralRe: try and catch, not sure how to handle catch Pin
jkirkerx7-May-12 12:58
professionaljkirkerx7-May-12 12:58 
AnswerRe: try and catch, not sure how to handle catch Pin
Aescleal8-May-12 3:55
Aescleal8-May-12 3:55 
Unfortunately CoCreateInstance isn't a C++ function so it won't throw exceptions - unless someone's implemented a wrapper or something around the function that we can't see in your example.

For COM and OLE functions you have to pull apart the HRESULT return value, preferably using the Microsoft macros and/or call GetLastError/FormatMessage. It's a pain in the bum but COM and OLE are pretty old now and MS haven't quite managed to kill it off or hide it yet.

What the various return values mean can be found here[^].

Edit for English fail.
GeneralRe: try and catch, not sure how to handle catch Pin
jkirkerx8-May-12 6:55
professionaljkirkerx8-May-12 6:55 
QuestionCan not Find Functions In Static Library Pin
AmbiguousName7-May-12 1:37
AmbiguousName7-May-12 1:37 
AnswerRe: Can not Find Functions In Static Library Pin
Chris Meech7-May-12 4:10
Chris Meech7-May-12 4:10 
AnswerRe: Can not Find Functions In Static Library Pin
Albert Holguin7-May-12 7:33
professionalAlbert Holguin7-May-12 7:33 
GeneralRe: Can not Find Functions In Static Library Pin
AmbiguousName7-May-12 7:42
AmbiguousName7-May-12 7:42 
AnswerRe: Can not Find Functions In Static Library Pin
Chuck O'Toole7-May-12 8:09
Chuck O'Toole7-May-12 8:09 
AnswerRe: Can not Find Functions In Static Library Pin
AmbiguousName7-May-12 18:47
AmbiguousName7-May-12 18:47 
AnswerRe: Can not Find Functions In Static Library Pin
Chuck O'Toole7-May-12 19:41
Chuck O'Toole7-May-12 19:41 
GeneralRe: Can not Find Functions In Static Library Pin
AmbiguousName7-May-12 20:10
AmbiguousName7-May-12 20:10 
AnswerRe: Can not Find Functions In Static Library Pin
Chuck O'Toole8-May-12 3:46
Chuck O'Toole8-May-12 3:46 
AnswerRe: Can not Find Functions In Static Library Pin
AmbiguousName8-May-12 9:06
AmbiguousName8-May-12 9:06 
QuestionCRichEditCtrl interface question Pin
ForNow6-May-12 6:32
ForNow6-May-12 6:32 
AnswerRe: CRichEditCtrl interface question Pin
enhzflep6-May-12 7:21
enhzflep6-May-12 7:21 
GeneralRe: CRichEditCtrl interface question Pin
ForNow6-May-12 9:07
ForNow6-May-12 9:07 
GeneralRe: CRichEditCtrl interface question [modified] Pin
enhzflep6-May-12 10:14
enhzflep6-May-12 10:14 
GeneralRe: CRichEditCtrl interface question Pin
enhzflep6-May-12 11:01
enhzflep6-May-12 11:01 
GeneralRe: CRichEditCtrl interface question Pin
ForNow7-May-12 7:24
ForNow7-May-12 7:24 

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.