Parsing and extracting content from Notes OLE Objects (version 2.04 May 2020)


 Product:

 General Information > Extracting content from OLE Objects > Version All

 Platform(s):

 All

 Edition(s):

 All

 Doc Number:

 1000115
Published 06-Mar-2019
Last Updated: 18-May-2020

 General Information

This support note provides a detailed and easily understandable description of Notes Object Linking & Embedded (OLE) objects / files. Content covered in the attached PDF file includes the structure of OLE objects, how to parse them, and how to extract the usable / editable content from them. A sample application has also been attached with full code for the parsing of OLE objects.

 Solution

OLE objects stored in Notes documents are a special type of attachment containing embedded data from other applications (for example Microsoft Excel or Word).

The content for OLE objects may either be embedded (contained within the OLE object itself) or linked (where the content is contained in an externally stored file). Linked objects all point to the same source data so any updates performed on a linked object update the centrally linked file – this also requires end users to be able to access the linked file. Embedded objects have the full content stored within the object itself (and the object is stored in the Notes document) and can therefore be updated by anyone with edit access rights to the document.

Notes supports the embedding of files as OLE/1 or OLE/2 objects. For platforms that support OLE the files are embedded as OLE/2 objects and for all other platforms as OLE/1 objects. If calling the EmbedObject method from Java files are stored as OLE/1 objects. OLE objects created in Notes 3.x or earlier are also stored in OLE/1 format.

Technical Documentation
The PDF file below contains detailed and easily understandable description of Notes OLE objects. Content covered in the file includes the structure of OLE objects, how to parse them, and how to extract the usable / editable content from them.

Notes OLE File Format and Parsing.pdfNotes OLE File Format and Parsing.pdf

Sample Application and Code
The attached sample application contains an agent and several LotusScript libraries for the processing of OLE objects and extracting the content from them.

The main LotusScript library class is called Compound File Parser - it handles all the steps of extracting the raw OLE object from a Notes document, parsing the binary data in the OLE object, and extracting the embedded content to a file that can be used. You may use the code in the attached sample application in your own applications.

The above PDF file contains information regarding the sample application, how to use it, and how to incorporate the design elements into your own applications. Also included in the file is code demonstrating how to use the Compound File Parser class and other script libraries to process OLE objects, parse the content in them, and extract the embedded content to files which can be used as normal files.

The below sample application contains several documents with a mixture of OLE/1 and OLE/2 objects of different classes (eg. Microsoft Word Document, PowerPoint Presentation, xml file). An agent called Extract Selected Documents demonstrates the processing of each selected Notes document and the embedded OLE objects in them. The agent detects the type of OLE object (ie. OLE/1 or OLE/2) and calls the appropriate methods to process them.

OLEParser.nsfOLEParser.nsf

Migrating content from Notes to other systems
The Export Utility for Notes enables you to easily migrate the content in any Notes database to the following formats: PDF, HTML, Microsoft Word, Microsoft Access, Microsoft Excel, IBM Connections, XML, and character delimited files such as Comma Delimited (CSV), Tab, Fixed Width, and more. The Export Utility can also extract all file attachments and convert embedded OLE objects to files.

For more information and to try it out please refer to the product information page: https://www.agecom.com.au/export



  Related Attachments


2020 AGE Computer Consultancy. All rights reserved.
Material may not be reproduced or distributed in any form without permission.