在iPhone上以编程方式从收件箱中读取电子邮件

问题描述:

我的iOS应用可以访问Mail应用中的用户的电子邮件收件箱吗?我想要阅读电子邮件并保存附件。

Is it possible for my iOS app to access the user's email inbox in the Mail app? I would like to be able to read the emails and save the attachments.

否。苹果不提供API。

No. Apple doesn't provide an API for that.

然而,您可以自由地询问用户的邮件服务器设置,然后直接与IMAP服务器进行通讯,下载附件自己。

However, you're free to ask the user for their mail server settings and then talk directly to an IMAP server, downloading the attachments yourself.

如果您有流行的电子邮件提供商(MobileMe,Gmail,Yahoo等)的预设,这对大多数用户来说不必太难处理。

If you have presets for popular email providers (MobileMe, Gmail, Yahoo, etc.) this won't have to be too difficult for most users to deal with.