I'd like to import and export from a Cocoa application from/to OpenOffice format. Spreadsheets, in particular, but also potentially text.
I've looked, but I can't seem to find the right combination of search words.
I'd like to import and export from a Cocoa application from/to OpenOffice format. Spreadsheets, in particular, but also potentially text.
I've looked, but I can't seem to find the right combination of search words.
Text is rather easy as OpenDocument text documents are directly supported by the Cocoa Text System since OS X 10.5. Thus, if you use that, you'll get ODT import and export for free.
Unfortunately, there is no native support for spreadsheets that I'm aware of. The format isn't too hard to grok though and especially export functionality should be something you should be able to get going without too much trouble. Have a look at the spec and at David Eisenberg's OpenDocument Essentials. A basic importer shouldn't be too hard either but it depends on your specific requirements. Avoid offering round-trip functionality with other ODF applications and stick to ODF import/export unless it is critical for your users to collaborate on ODF documents with users of other ODF applications. Good luck.