Click here to Skip to main content
16,006,442 members
Home / Discussions / COM
   

COM

 
GeneralRe: How can I get an array of datas from COM server? Pin
soptest13-May-02 10:28
soptest13-May-02 10:28 
AnswerRe: How can I get an array of datas from COM server? Pin
soptest13-May-02 10:24
soptest13-May-02 10:24 
GeneralRe: How can I get an array of datas from COM server? Pin
magicast14-May-02 1:42
magicast14-May-02 1:42 
GeneralUse Com in Multithread Pin
ssirisha10-May-02 4:58
ssirisha10-May-02 4:58 
GeneralRe: Use Com in Multithread Pin
Joao Vaz14-May-02 7:02
Joao Vaz14-May-02 7:02 
GeneralRe: Use Com in Multithread Pin
Srini Kella15-May-02 10:15
Srini Kella15-May-02 10:15 
GeneralERROR when using Midl... Pin
Dan Madden9-May-02 8:56
Dan Madden9-May-02 8:56 
GeneralCalling Com object from a worker thread Pin
ssirisha9-May-02 4:16
ssirisha9-May-02 4:16 
What's worng with the following code. I am getting
"Unhandled exception in XYZ.exe (OLE32.DLL):0xC000005: Access Violation"

(Note: This message board is eating off any thing within < > and hence you will find << >> instead of < > to avoid it)

#import <<comapp.dll>> no_namespace

class CMyClass :: public CWinApp
{
....
public:
CWinThread *m_Thread;
static UINT WorkerThreadProc(LPVOID pParam);
IComAppPtr g_pIComApp;
...
};

CMyClass::CMyClass()
{
g_pIComApp = *(new IComAppPtr(__uuidof(ComApp)));
g_pIComApp->XYZ();

m_Thread = AfxBeginThread((AFX_THREADPROC)WorkerThreadProc, static_cast<<lp_void>>(this), THREAD_PRIORITY_ABOVE_NORMAL, 0);
};

UINT CMyClass::WorkerThreadProc(LPVOID pParam)
{
CMyClass *mPtr = static_cast<<cmyclass *="">>(pParam);

/*******************************
// Whats wrong here? When I call the following function
// I get ACCESS VIOLATION OLE32.dll
mPtr->g_pIComApp->XYZ();
//******************************************

};

Thanks for your help.
GeneralRe: Calling Com object from a worker thread Pin
Tim Smith9-May-02 4:32
Tim Smith9-May-02 4:32 
GeneralRe: Calling Com object from a worker thread Pin
ssirisha9-May-02 5:05
ssirisha9-May-02 5:05 
GeneralRe: Calling Com object from a worker thread Pin
14-May-02 2:05
suss14-May-02 2:05 
GeneralCOM Status in .NET Pin
zakimurtaza8-May-02 20:05
zakimurtaza8-May-02 20:05 
GeneralRe: COM Status in .NET Pin
Tom Archer9-May-02 22:35
Tom Archer9-May-02 22:35 
GeneralRe: COM Status in .NET Pin
zakimurtaza12-May-02 6:11
zakimurtaza12-May-02 6:11 
GeneralRe: COM Status in .NET Pin
Tom Archer12-May-02 6:19
Tom Archer12-May-02 6:19 
Questionhow to load a conventional DLL in a COM Server? Pin
GooGoo8-May-02 19:20
GooGoo8-May-02 19:20 
AnswerRe: how to load a conventional DLL in a COM Server? Pin
-Dy8-May-02 23:49
-Dy8-May-02 23:49 
GeneralRe: how to load a conventional DLL in a COM Server? Pin
GooGoo9-May-02 17:33
GooGoo9-May-02 17:33 
GeneralRe: how to load a conventional DLL in a COM Server? Pin
-Dy9-May-02 22:43
-Dy9-May-02 22:43 
Questionhow to register a com dll with c++ code? Pin
7-May-02 14:25
suss7-May-02 14:25 
AnswerRe: how to register a com dll with c++ code? Pin
Paul M Watt7-May-02 14:51
mentorPaul M Watt7-May-02 14:51 
AnswerRe: how to register a com dll with c++ code? Pin
safepage14-May-02 3:29
safepage14-May-02 3:29 
AnswerRe: how to register a com dll with c++ code? Pin
Carlos Antollini14-May-02 4:55
Carlos Antollini14-May-02 4:55 
QuestionDo I need Variants for VB compatability? Pin
JohnnyG7-May-02 9:56
JohnnyG7-May-02 9:56 
AnswerRe: Do I need Variants for VB compatability? Pin
soptest7-May-02 11:08
soptest7-May-02 11:08 

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.