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. CoGetClassObject( ) and Shell extension

CoGetClassObject( ) and Shell extension

Scheduled Pinned Locked Moved COM
comwindows-adminlinuxhelpquestion
1 Posts 1 Posters 0 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.
  • J Offline
    J Offline
    Jin Yao
    wrote on last edited by
    #1

    Hello all, In my shell extension dll, there are some codes like that (call another COM component): ...... hr = CoGetClassObject(CLSID_Class1, CLSCTX_ALL, NULL, IID_IClassFactory, (void**)&pcf); (now hr = S_OK) hr = pcf->CreateInstance(NULL, IID_Interface1, (void**)&pi); (ERROR: "Can't find the registered interface") CLSID_Class1 is also a COM component written by myself and I've written a simple exe app to test this component and find it runs ok. So it means the GUIDs have been registered in the registry successfully and the component itself is correct. Why the shell extension dll calls the CLSID_Class1 component will be fail but the exe application calls it successfully? Both the shell extension COM and CLSID_Class COM are all "Apartment" thread model. Thanks a lot

    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