使用Objective-C获取Outlook .msg文件内容 [英] Getting Outlook .msg file contents with Objective-C

查看:147
本文介绍了使用Objective-C获取Outlook .msg文件内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为iPhone和iPad编写应用程序,我需要它来显示Outlook .msg文件的预览。不出所料,Quick Look不支持这种文件类型,因此我需要一些解析内容的方法。

I am writing an app for the iPhone and iPad and I need it to show a preview of an Outlook .msg file. Quick Look, unsurprisingly, doesn't support this file type and therefore I need some way of parsing the contents.

有没有办法获取文件?我希望能够将内容视为HTML(即使我之后必须稍微操作内容)我已经看到了在Windows中使用OLE流和可能的XML解析的参考但不确定它们如何应用于Objective-C 。有针对iOS的.msg阅读器应用程序,所以我知道它可能但很难做到。

Is there any way of getting the contents of an Outlook .msg file with Objective-C? I want to be able to view the contents as HTML (even if I have to manipulate the contents a bit afterwards) I've seen references made to using OLE streams and possibly XML parsing in Windows but not sure how these apply in Objective-C. There are .msg reader apps out there for iOS, so I know it's possible but struggling to do it.

感谢您的帮助。

推荐答案

Outlook .msg文件存储为 OLE复合文档(又名 COM stuctured storage )。所以你主要需要一个库来读取这种格式。快速搜索 POLE libgsf 。它们分别用C ++和C语言编写,但也支持iPhone。

Outlook .msg files are stored as OLE compound documents (aka COM stuctured storage). So you mainly need a library to read this format. A quick search turned up POLE and libgsf. They are written in C++ and C, respectively, but that's supported on the iPhone as well.

然后有一些文件格式信息,显示复合文档格式如何用于存储电子邮件的不同部分。

Then there's some file format information that shows how the compound document format is used to store the different parts of an email.

这篇关于使用Objective-C获取Outlook .msg文件内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆