Click here to Skip to main content
16,004,924 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Registry vs MS Service Pin
Anders Molin1-Apr-03 22:02
professionalAnders Molin1-Apr-03 22:02 
General“EDIT” window and string storing Pin
sathyashrayan1-Apr-03 17:56
sathyashrayan1-Apr-03 17:56 
GeneralRe: “EDIT” window and string storing Pin
Rickard Andersson201-Apr-03 22:57
Rickard Andersson201-Apr-03 22:57 
GeneralRe: “EDIT” window and string storing Pin
sathyashrayan2-Apr-03 1:19
sathyashrayan2-Apr-03 1:19 
GeneralRe: “EDIT” window and string storing Pin
John R. Shaw2-Apr-03 10:53
John R. Shaw2-Apr-03 10:53 
QuestionCoCreateInstance fail? Pin
Kevein1-Apr-03 17:49
Kevein1-Apr-03 17:49 
AnswerRe: CoCreateInstance fail? Pin
Dave Bryant1-Apr-03 18:12
Dave Bryant1-Apr-03 18:12 
AnswerRe: CoCreateInstance fail? Pin
Aisha Ikram1-Apr-03 19:48
Aisha Ikram1-Apr-03 19:48 
As said by Dave, CoCreateInstance() can return any possible HRESULT value. The most common HRESULT values are S_OK, S_FALSE and E_FAIL. You can use the error look up table or check the hr value of your returned HRESULT in your watch window while debugging.

For example:
<br />
HRESULT hRes = CoCreateInstance(.....);<br />


insert in your watch, a variable hRes,hr and check the error string when you pass the CoCreate statement.

Also make sure you are specifying proper parameters to CoCreateInstance and that you are releasing the referrence count using Release() method after the first time creation of your component using CoCreateInstance.

@!$h@
AnswerRe: CoCreateInstance fail? Pin
Kevein2-Apr-03 6:02
Kevein2-Apr-03 6:02 
GeneralRe: CoCreateInstance fail? Pin
Aisha Ikram3-Apr-03 0:20
Aisha Ikram3-Apr-03 0:20 
GeneralRe: CoCreateInstance fail? Pin
Aisha Ikram3-Apr-03 0:20
Aisha Ikram3-Apr-03 0:20 
GeneralRe: CoCreateInstance fail? Pin
Kevein3-Apr-03 6:38
Kevein3-Apr-03 6:38 
GeneralRe: CoCreateInstance fail? Pin
Aisha Ikram3-Apr-03 17:43
Aisha Ikram3-Apr-03 17:43 
Generalwininet.lib linker error in VC7 Pin
Paul Lyons1-Apr-03 15:58
Paul Lyons1-Apr-03 15:58 
GeneralRe: wininet.lib linker error in VC7 Pin
paulb1-Apr-03 19:53
paulb1-Apr-03 19:53 
GeneralDetection of OCX File Pin
Coremn1-Apr-03 15:32
Coremn1-Apr-03 15:32 
GeneralRe: Detection of OCX File Pin
bryce1-Apr-03 15:54
bryce1-Apr-03 15:54 
GeneralRe: Detection of OCX File Pin
Coremn1-Apr-03 16:23
Coremn1-Apr-03 16:23 
GeneralRe: Detection of OCX File Pin
Aisha Ikram3-Apr-03 19:28
Aisha Ikram3-Apr-03 19:28 
GeneralRe: Detection of OCX File Pin
Coremn2-Apr-03 15:34
Coremn2-Apr-03 15:34 
GeneralRe: Detection of OCX File Pin
Aisha Ikram3-Apr-03 17:56
Aisha Ikram3-Apr-03 17:56 
GeneralUse "SetDIBitsToDevice" to show JPEG image Pin
Tossporn1-Apr-03 15:10
Tossporn1-Apr-03 15:10 
GeneralUsing Old C libraries with C++ libraries Pin
dahicke1-Apr-03 14:15
dahicke1-Apr-03 14:15 
GeneralRe: Using Old C libraries with C++ libraries Pin
dahicke2-Apr-03 12:32
dahicke2-Apr-03 12:32 
GeneralTranslating Accelerator From Dialog to MainFrame :: MFC Pin
valikac1-Apr-03 14:14
valikac1-Apr-03 14:14 

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.