Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. COM
  4. ATL and Connection Points

ATL and Connection Points

Scheduled Pinned Locked Moved COM
c++comsysadminquestion
2 Posts 2 Posters 3 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    Lost User
    wrote on last edited by
    #1

    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.

    R 1 Reply Last reply
    0
    • L Lost User

      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.

      R Offline
      R Offline
      Ryan Park
      wrote on last edited by
      #2

      What was the returned HRESULT code? Regards, Ryan

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups