Click here to Skip to main content
15,899,026 members
Home / Discussions / COM
   

COM

 
QuestionUnable to register simpleui5.ocx in system32 Pin
Hunzian31-Mar-10 23:55
Hunzian31-Mar-10 23:55 
AnswerRe: Unable to register simpleui5.ocx in system32 Pin
Adam Roderick J2-Apr-10 18:22
Adam Roderick J2-Apr-10 18:22 
QuestionHow to Sink Current IE IWebBrowser Interface? Pin
twblue31-Mar-10 17:55
twblue31-Mar-10 17:55 
Questionhow to register OCX on the 64 bit vista machine Pin
PrafullaShirke2723-Mar-10 19:59
professionalPrafullaShirke2723-Mar-10 19:59 
AnswerRe: how to register OCX on the 64 bit vista machine Pin
KingsGambit23-Mar-10 23:36
KingsGambit23-Mar-10 23:36 
AnswerRe: how to register OCX on the 64 bit vista machine Pin
Abhinav S27-Mar-10 19:50
Abhinav S27-Mar-10 19:50 
QuestionError handling using HRESULT Pin
PaulowniaK23-Mar-10 19:32
PaulowniaK23-Mar-10 19:32 
AnswerRe: Error handling using HRESULT PinPopular
Stephen Hewitt23-Mar-10 21:36
Stephen Hewitt23-Mar-10 21:36 
Firstly note that there are multiple success and failure code. If you're only interested in failure or success (and not the type of failure or success) then you can use the FAILED and SUCCEEDED macros:
HRESULT hr = pObj->SomeMethod();
 
if (FAILED(hr))
{
    // Failed!
}
 
if (SUCCEEDED(hr))
{
    // Succeeded!
}


A HRESULT is made from a number of components. The easiest way to create one from its component parts is with the MAKE_HRESULT[^] macro.

To make a user defined error code to be returned from a COM interface you'd do something like this (MS recommends error values in the range 0x0200 to 0xffff):
MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x200)


The structure of a HRESULT is shown here[^].

Some more information is here[^].
Steve

AnswerRe: Error handling using HRESULT Pin
KarstenK6-Apr-10 21:27
mveKarstenK6-Apr-10 21:27 
QuestionCom Exe server Pin
ashish8patil21-Mar-10 20:28
ashish8patil21-Mar-10 20:28 
AnswerRe: Com Exe server Pin
KingsGambit21-Mar-10 23:09
KingsGambit21-Mar-10 23:09 
GeneralRe: Com Exe server Pin
ashish8patil22-Mar-10 4:11
ashish8patil22-Mar-10 4:11 
GeneralRe: Com Exe server Pin
KingsGambit22-Mar-10 20:36
KingsGambit22-Mar-10 20:36 
AnswerRe: Com Exe server Pin
Adam Roderick J24-Mar-10 19:36
Adam Roderick J24-Mar-10 19:36 
Questionhow to connection to a remote sql server via ado? [modified] Pin
kcynic20-Mar-10 23:43
kcynic20-Mar-10 23:43 
AnswerRe: how to connection to a remote sql server via ado? Pin
T21024-Apr-10 20:49
T21024-Apr-10 20:49 
QuestionGIT CPU usage Pin
marko201019-Mar-10 15:13
marko201019-Mar-10 15:13 
QuestionQuestion on Regcomplus.exe Pin
Simon Mandy19-Mar-10 8:44
Simon Mandy19-Mar-10 8:44 
QuestionDrag and drop shell extension blocking explorer.exe Pin
Sebastien Mongrain19-Mar-10 8:15
Sebastien Mongrain19-Mar-10 8:15 
QuestionIDispatch Pin
trioum18-Mar-10 2:23
trioum18-Mar-10 2:23 
AnswerRe: IDispatch Pin
Stephen Hewitt20-Mar-10 22:08
Stephen Hewitt20-Mar-10 22:08 
AnswerRe: IDispatch Pin
Cool_Dev21-Mar-10 23:59
Cool_Dev21-Mar-10 23:59 
GeneralRe: IDispatch Pin
trioum26-Mar-10 7:57
trioum26-Mar-10 7:57 
GeneralRe: IDispatch Pin
Cool_Dev27-Mar-10 2:55
Cool_Dev27-Mar-10 2:55 
GeneralRe: IDispatch Pin
trioum16-Apr-10 21:26
trioum16-Apr-10 21:26 

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.