Question

Need very quick help.. When an email is configured in iPad then Settings app will store this account information. Programmatically I want to access this default email account configured in Settings App of the iPad. I just want to know is it yahoo or gmail or any type and possibly the user name.

Is it possible to extract this information programmatically, may be using NSUserDefaults or any other settings or preferences ? Please suggest..

Was it helpful?

Solution

There is no API nor an NSUserDefaults key that provides the "default" e-mail address. I've read about some third-party APIs that do this that make use of undocumented APIs, but any app making use of these will almost certainly be rejected by Apple upon review after submission. Your best bet is to ask the user which e-mail address they want to use for your app—or, for that matter, if your app simply involves sending an e-mail, use the MFMailViewComposeViewController class.

OTHER TIPS

There is no way to access any information about a user's email account settings. You must ask the user to provide the details to your app.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top