ATL and Connection Points
-
Hi, I Created a COM object(Client) which is to be connected to a COM exe( server ). Below is the piece of code i am executing....... This code is inside the method of a ATL full control........ //CLSID_Service is the coClass of my COM exe if(pService == NULL) { hr = CoCreateInstance(CLSID_Service,NULL,CLSCTX_LOCAL_SERVER,IID_IService,(void**)&pService); if(FAILED(hr)) return hr; } CComObject *pServiceClient; CComObject::CreateInstance(&pServiceClient); hRes = AtlAdvise(pService, pServiceClient->GetUnknown(), IID_IServiceCDKLinkEvents, &m_dwAdvise); with this above code my AtlAdvise() failed....... What would be the reason......... CServiceClient is a COM object implementing the interfaceIID_IServiceCDKLinkEvents of the CLSID_Service Any idea?? Thanks in Advance, Aruna.
-
Hi, I Created a COM object(Client) which is to be connected to a COM exe( server ). Below is the piece of code i am executing....... This code is inside the method of a ATL full control........ //CLSID_Service is the coClass of my COM exe if(pService == NULL) { hr = CoCreateInstance(CLSID_Service,NULL,CLSCTX_LOCAL_SERVER,IID_IService,(void**)&pService); if(FAILED(hr)) return hr; } CComObject *pServiceClient; CComObject::CreateInstance(&pServiceClient); hRes = AtlAdvise(pService, pServiceClient->GetUnknown(), IID_IServiceCDKLinkEvents, &m_dwAdvise); with this above code my AtlAdvise() failed....... What would be the reason......... CServiceClient is a COM object implementing the interfaceIID_IServiceCDKLinkEvents of the CLSID_Service Any idea?? Thanks in Advance, Aruna.