FindConnectionPoint method returning null connection point

268 views Asked by At

I found this POST which near about resembles my code while doing COM Interop Event Handling using IConnectionPoints Interface.
Please suggest me if you have any information related to this topic.

I know that FindConnectionPoint returns NULL if there is an error in COnnectionPoint with the source interface(EventInterface).

I checked my COM object supporting the source interface by QueryInterface method(P.S::HRESULT returns S_OK).

What type of error is occurring here?
Please refer to the post. I have the same problem. UPDATE: My tlh file snapshot>>

//
// Named GUID constants initializations
//

extern "C" const GUID __declspec(selectany) LIBID_CSharp =
    {0x4e5098b7,0x4e51,0x45e5,{0xa7,0x05,0xa7,0xe3,0xc5,0x1e,0x2a,0x80}};
extern "C" const GUID __declspec(selectany) CLSID_PropertyChangeEventArgs =
    {0xe3a5b5e1,0xda28,0x32cf,{0x93,0x9c,0x18,0x6e,0x90,0xe8,0xd1,0x08}};
extern "C" const GUID __declspec(selectany) IID_ISomeInterface =
    {0x5f4c254f,0xa363,0x4afd,{0xad,0x5d,0x6d,0x52,0x83,0xfa,0x5e,0x59}};
extern "C" const GUID __declspec(selectany) CLSID_Class1 =
    {0xf08e4034,0x6904,0x49c4,{0xa2,0x89,0x52,0xf2,0x72,0xc9,0xe6,0x58}};
extern "C" const GUID __declspec(selectany) IID__DownloadEventArgs =
    {0x6df89fd5,0xa7be,0x3699,{0x98,0x57,0xa3,0xe2,0xec,0x69,0xd2,0x60}};
extern "C" const GUID __declspec(selectany) IID_ISomeEventsInterface =
    {0x1e430900,0xd303,0x490a,{0xa4,0x73,0xca,0x91,0x46,0xc6,0x7e,0x75}};

} // namespace CSharp

My cpp file snapshot>>

IUnknown* pIUnknown ;
HRESULT hresult = CoInitialize(NULL);
IConnectionPointContainer* pIConnectionPointContainerTemp;
IConnectionPoint* pIConnectionPoint; 
DWORD* cookie=0;
CSharp::ISomeInterfacePtr pIsomeInterface(__uuidof(CSharp::Class1));
hresult=CoCreateInstance(__uuidof(CSharp::Class1), NULL, CLSCTX_INPROC_SERVER, IID_IUnknown, (void**)&pIUnknown);
hresult=pIsomeInterface->QueryInterface(IID_IConnectionPointContainer, (void**)&pIConnectionPointContainerTemp);
pIConnectionPointContainerTemp->FindConnectionPoint(CSharp::IID_ISomeEventsInterface ,&pIConnectionPoint);//Added QUICK watch here>>raised error here CXX0017: Error: symbol "ManagedDLL::IID_ISomeEventsInterface " not found 
0

There are 0 answers