Differences Between OleClose and OleDelete Functions

Last reviewed: February 17, 1995
Article ID: Q72638
The information in this article applies to:
  • Microsoft OLE version 1.0

The following information applies to version 1.0 of the OLE extensions to Windows.

There has been some confusion concerning the use of the OleClose and OleDelete functions. OleClose is used to close an object, while OleDelete closes the object and deletes it, reclaiming its storage.

Since dynamic data exchange (DDE) is the underlying information transport mechanism for the OLE protocol, closing an object simply terminates the DDE conversation between the OLE client and the OLE server. This conversation can be restarted by calling OleReconnect. Performing a reconnect is valid only for linked objects that are already open in their server. Attempting to reconnect to an object that is not open in its server will fail.

OleDelete closes the object as well, but also frees the memory associated with the object. Calling OleDelete notifies the OLE library that the specified object is no longer part of the client document.


Additional reference words: 1.00 3.10 OL&E
KBCategory: kbole kbprg
KBSubcategory: LeoneSvrStop


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: February 17, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.