WriteInterfacePtr simply writes the address of the IDispatch interface associated with the object, nothing more. It is your responsability to do thigns like AddRef and Release to make sure the object is not destroyed before the interface pointer is read back.
If you have a particular example of something you want to do, please post