Document Export

OmniOutliner supports the export of outlines to documents of various formats, such as to standard office, spreadsheet, text, and HTML formats.

This section examines how to create File Wrappers in preparation for the export of documents and content.

Documentation regarding the other classes involved in the saving and export of OmniPlan documents can be found in FileTypes and FileSavers.


If you think of an outline as a set of data, then it’s easy to understand that an outline’s data can be packaged in a variety of ways. Each “data package” has a set of parameters that determine how the outline data is stored or presented.

For example, one package may store the data as tabbed data, while another may store the outline data in XML format. Each of the supported file packaging formats has its own set of parameters. In terms of Omni Automation, these file packages are referred to as FileWrappers.

Each FileWrapper has a unique type identifier that identifies that wrapper. To get a list of the export types supported by OmniOutliner, write a simple script to access the value of the writableTypes property of the Document class. The result will be an array of the identifiers for the FileWrappers supported in OmniOutliner.

NOTE: a complete list of all readable and writeable filetypes supported by OmniOutliner is available here.

A writable type is used when creating a new file wrapper instance:

wrapper = document.fileWrapper('com.omnigroup.OmniOutliner.CSVExport.CSV')

Instance Properties

Each FileWrapper instance has a set of supported properties, most of which have values that are read-only, with the exception of the preferredFilename property whose value can be set in a script.

wrapper = document.fileWrapper('com.omnigroup.OmniOutliner.CSVExport.CSV') wrapper.preferredFilename = "My Tabbed Export.csv"

The value of the contents property is a representation of the outline data, which can be manipulated using class and instance functions from the Data class:

wrapper = document.fileWrapper('com.omnigroup.OmniOutliner.CSVExport.CSV') wrapper.preferredFilename = "My Tabbed Export.csv" encodedData = wrapper.contents.toBase64()

Class Functions

The class functions for the FileWrapper class:

Instance Functions

The instance functions for the FileWrapper class:


The class properties of a FileWrapper.Type:

As mentioned previously, here is a full explanation of the FileWrapper.Types supported by OmniOutliner:

Here are the various export formats with their corresponding FileWrapper.Type:

When exporting a multi-column outline as CSV, OmniOutliner saves the .csv file using standard comma-separated values (CSV) conventions (i.e., each column is separated by a comma, and text with spaces is placed within quotations).
Excel 2010 Format
Creates a .xlsx spreadsheet document capable of being read in Microsoft Excel 2010 (and other versions of Excel that support the format). This export option maps most closely to multi-column data outside OmniOutliner, and does its best to replicate styles between the two (within the limits of Excel).
Creates a like-named folder that contains an index.html file along with the necessary images and attachments that make up your OmniOutliner file. All of the styles you’ve used in OmniOutliner are converted to CSS and included in the index.html file.
HTML (Dynamic)
This option gives you everything that comes with the basic HTML export, plus an added outliner.js file. This JavaScript file is what makes the file dynamic; you can open and close the sections of your document just as you would in OmniOutliner.
Microsoft Word (indented)
Creates a .docx file that opens in the default page layout view and retains the outline structure via indentation. This export option only includes the topic column, and is primarily useful for transitioning from an outline to a word processor (rather than duplicating OmniOutliner’s functionality in Word). Row level styles are converted to heading styles, and other styles are flattened and applied directly to text (Microsoft Word does not support OmniOutliner’s style model).
Microsoft Word (outline)
Creates a .docx file that opens by default in Microsoft Word’s Outline view. Choose this option to export an outline that can be readily expanded upon in Word. This export option only includes the topic column.
OmniOutliner Document
Exports a .ooutline file, the current default OmniOutliner file format (for OmniOutliner 5 and later).
OmniOutliner Template
Exports a .otemplate file which can be used as the base theme for other OmniOutliner outlines. This template format is not compatible with versions earlier than OmniOutliner 5.
OmniOutliner 3
Exports a .oo3 file which can be opened in either OmniOutliner 3 or 4 for Mac, and in OmniOutliner 1 for iPad and OmniOutliner 2 for iOS. These files are not compatible with OmniOutliner 2 for Mac and earlier. They can be opened in OmniOutliner 5, but must be updated to the newer .ooutline format before all editing features are available.
OmniOutliner 3 Template
Exports a .oo3template file which can be opened in either OmniOutliner 3 or 4. These files are not compatible with OmniOutliner 2 or earlier. They can be opened in OmniOutliner 5, but must be updated to the newer .otemplate format before they can be edited.
OPML (Outline Processor Markup Language)
Exports a .opml file, which retains the hierarchical structure of your outline. However, OPML files do not retain any of the styles or attachments you may have applied in OmniOutliner.
Plain Text (with tabs)
Exports a raw .txt file without any styles. Child rows and columns are aligned using tabs rather than spaces, making this type of export useful for importing into spreadsheet apps such as Numbers or Excel.
PowerPoint 2012 Format (pptx)
OmniOutliner exports the contents of your outline in an XML format that PowerPoint 2012 can interpret and render. After exporting your outline as .pptx, you can then import the PowerPoint file into Apple’s Keynote app.
Each Level 1 row becomes a separate slide in the PowerPoint presentation, with its children listed on that slide, and notes become presenter notes. Very little styling is carried over from OmniOutliner (styles don’t match well between the two formats, so we err on the side of removing them).
Image attachments are placed on slides corresponding to their level in the hierarchy, but must be manually repositioned to the desired location on the slide.
org.openxmlformats.presentationml.presentation.PowerPoint 2012 Format (pptx)
RTF (Rich Text Format)
Exports a .rtf file, which retains all of the styles you’ve applied in OmniOutliner. RTF is a standard document format that most word processors, such as Word and macOS’s TextEdit app can open. Export to RTF if your Outliner document contains only text and numbers.
RTFD (Rich Text Format with Attachments)
Exports a .rtfd file, which retains all of the styles you’ve applied in OmniOutliner. What sets RTFD apart from RTF is that an RTFD file can contain attachments, such as any images, audio clips, or anything else you attach to your OmniOutliner file. Most word processors, such as Word, Pages, and macOS’s TextEdit can open .rtfd files.

Export Examples

Here are some examples of using FileWrappers to export OmniOutliner documents.

Here’s an Omni Automation script for creating a new task in OmniFocus with the current OmniOutliner document as an attachment. The script uses the integrated URL support in OmniFocus to create and run a URL link for creating tasks:

wrapper = document.fileWrapper() taskName = encodeURIComponent( attachmentName = encodeURIComponent(wrapper.preferredFilename) encodedData = wrapper.contents.toBase64() urlStr = "omnifocus://localhost/add?name=" + taskName + "&attachment=" + encodedData + "&attachment-name=" + attachmentName URL.fromString(urlStr).call(function(result){})

 1  Create an instance of a FileWrapper for the document. Since no parameter is included within the parens, the default export settings are used.

 2  Encode the document name to be used as the name of the task.

 3  Encode the document file name to be used as the attachment name.

 4  Encode the contents of the document in Base 64 encoding format, which results in a string of URL approved characters.

 5  Combine the encoded elements into the URL format supported by OmniFocus.

 6  Convert the URL string into a URL object and execute it using the call() method.

More information about implementing the previous script as an Omni Automation action can be found here.

The following example script utilize the built-in eMail support in OmniOutliner to add export copies of the current document to new outgoing mail messages:

var wrapper = document.fileWrapper('public.plain-text') var email = new Email() email.subject = "Plain-Text Version of “" + + "”" email.body = "Here is the plain-text version of the document for you!\n\n" email.fileWrappers = [wrapper] email.generate()
var wrapper = document.fileWrapper('org.openxmlformats.presentationml.presentation.PowerPoint 2012 Format (pptx)') var email = new Email() email.subject = "Presentation of “" + + "”" email.body = "Here is the presentation version of the document for you!\n\n" email.fileWrappers = [wrapper] email.generate()
var wrappers = [] document.writableTypes.forEach(function(type){ var wrapper = document.fileWrapper(type) wrappers.unshift(wrapper) }); var email = new Email() email.subject = "Exports of “" + + "”" email.body = "Here are the exported document versions for you!\n\n" email.fileWrappers = wrappers email.generate()

This webpage is in the process of being developed. Any content may change and may not be accurate or complete at this time.