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. Thorwing a event with a collection

Thorwing a event with a collection

Scheduled Pinned Locked Moved COM
comsysadminperformancehelpquestion
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.
  • G Offline
    G Offline
    GizzoF
    wrote on last edited by
    #1

    I have a COM object that throws an event with a collection of others COM objects. I’m not sure about the way I have to do it. The code I have implemented is like.... ICollection * pInterfaceCollection; CCollection * pCollection = new CCollection (); pCollection->QueryInterface(IID_ICollection, (void**) &pInterfaceCollection); pInterfaceCollection->Release(); result = Fire_OnColletionItems(pInterfaceCollection); if(FAILED(result)) { ... } The problem here is that I have memory leaks. I fire the event, the client (an VB application) manages it, I shut down the client, and then I shut down my application (the server)... and there they are. I thought that the client was who release the object so I shouldn’t do it. How should I to do this? Thank you in advance. PD: sorry for my english -- modified at 13:54 Tuesday 27th September, 2005

    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