Click here to Skip to main content
15,898,987 members
Home / Discussions / COM
   

COM

 
GeneralRe: Why we need COM Pin
Nandu_77b19-Sep-07 5:31
Nandu_77b19-Sep-07 5:31 
GeneralRe: Why we need COM Pin
Baltoro4-Oct-07 12:44
Baltoro4-Oct-07 12:44 
QuestionAvoid hang of the component manager with com+ console messages [modified] Pin
Vider18-Sep-07 1:51
Vider18-Sep-07 1:51 
Questioncom and threading models,and a question about dlls? Pin
rozbeh18-Sep-07 0:18
rozbeh18-Sep-07 0:18 
AnswerRe: com and threading models,and a question about dlls? Pin
Nathan Holt at EMOM18-Sep-07 7:52
Nathan Holt at EMOM18-Sep-07 7:52 
QuestionCOM List over Network Pin
Fatbuddha 117-Sep-07 21:22
Fatbuddha 117-Sep-07 21:22 
Questionusing void ** in Interface Pin
tictactoer17-Sep-07 3:26
tictactoer17-Sep-07 3:26 
AnswerRe: using void ** in Interface Pin
Nathan Holt at EMOM17-Sep-07 9:59
Nathan Holt at EMOM17-Sep-07 9:59 
true627 wrote:
when it comes to COM,
ISomeCollection *pColl;
void *pV = NULL;
pColl->InternalObject(&pV);//signature is InternalObject (void**)

vector* pVec = (vector*) pV;

the above code is not working all the times.

Any suggestions for this code is highly appreciated.


I don't think you're supposed pass things like pointers to STL objects in COM, because you're supposed to not make clients depend on implementation details of your class. In particular, a process called "marshalling" depends on things being spelled out in .idl files in ways that STL doesn't guarentee. I think it would be more appropriate to provide "Item" for accessing specific items of the vector, and "Count" for finding the vector's size. If you need more access than that, you can write a "Contents" method which returns a pointer to the vector's contents and the number of elements, which can be described in IDL enough to be marshalled properly.

Nathan
GeneralRe: using void ** in Interface Pin
tictactoer19-Sep-07 0:00
tictactoer19-Sep-07 0:00 
GeneralRe: using void ** in Interface Pin
Nathan Holt at EMOM19-Sep-07 11:22
Nathan Holt at EMOM19-Sep-07 11:22 
QuestionProblem in adding a new function in existing Interface Pin
Ravikr0716-Sep-07 22:57
Ravikr0716-Sep-07 22:57 
AnswerRe: Problem in adding a new function in existing Interface Pin
Nathan Holt at EMOM17-Sep-07 10:07
Nathan Holt at EMOM17-Sep-07 10:07 
GeneralRe: Problem in adding a new function in existing Interface Pin
Ravikr0717-Sep-07 10:25
Ravikr0717-Sep-07 10:25 
GeneralRe: Problem in adding a new function in existing Interface Pin
Nathan Holt at EMOM17-Sep-07 11:08
Nathan Holt at EMOM17-Sep-07 11:08 
GeneralRe: Problem in adding a new function in existing Interface Pin
Ravikr0717-Sep-07 19:37
Ravikr0717-Sep-07 19:37 
GeneralRe: Problem in adding a new function in existing Interface Pin
Nathan Holt at EMOM18-Sep-07 7:24
Nathan Holt at EMOM18-Sep-07 7:24 
GeneralRe: Problem in adding a new function in existing Interface Pin
paresh_joe26-Sep-07 2:50
paresh_joe26-Sep-07 2:50 
QuestionGetting a ('support_error_info' : attribute not found) error Pin
monsieur_jj16-Sep-07 21:15
monsieur_jj16-Sep-07 21:15 
AnswerRe: Getting a ('support_error_info' : attribute not found) error Pin
Nathan Holt at EMOM17-Sep-07 10:13
Nathan Holt at EMOM17-Sep-07 10:13 
QuestionAxtiveX, this pointer [modified] Pin
m1m216-Sep-07 10:38
m1m216-Sep-07 10:38 
QuestionCan i use a dll in an activeX component? Pin
just3ala215-Sep-07 10:04
just3ala215-Sep-07 10:04 
AnswerRe: Can i use a dll in an activeX component? Pin
Nathan Holt at EMOM17-Sep-07 10:17
Nathan Holt at EMOM17-Sep-07 10:17 
GeneralRe: Can i use a dll in an activeX component? Pin
just3ala217-Sep-07 12:26
just3ala217-Sep-07 12:26 
QuestionDifference between .idl and .h file? Pin
Ash2014-Sep-07 0:23
Ash2014-Sep-07 0:23 
AnswerRe: Difference between .idl and .h file? Pin
Hubert Mayer14-Sep-07 4:58
Hubert Mayer14-Sep-07 4:58 

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.