How to open the Mail app?Just open without sending email - ios

The requirement is open the Mail app, just like custom url scheme open the app but do nothing else.
Use #"mailto://" url will open the Mail app with a new email in edting, that's not what I want.
any ideas?
sorry about my poor English.

Related

Deep link to specific message in Gmail app

I successfully have a message url from the gmail api:
https://mail.google.com/mail/?authuser=roy#companyemail.co#all/155134b5e66a9b06
However, when i call the [[UIApplication sharedApplication] openURL:url] method, the web client gets opened up instead of the native iOS application (and just shows the inbox, not the specific message). Not sure if it has to do with the LSApplicationQueriesSchemes or not, but regardless - couldn't find any documentation on this in the Gmail iOS documentation, so if anyone has any ideas!
Thanks
Through the links the Brett posted, this deep link url allowed me to open gmail:
googlegmail://
Still searching for instructions on deep linking to a specific email though
It seems that the openURL method is designed to do what you want to do. But any URL which starts with http: or https: is going to open in Safari. Here is a quote from the doco.
A URL (Universal Resource Locator). UIKit supports many common
schemes, including the http, https, tel, facetime, and mailto schemes.
You can also employ custom URL schemes associated with apps installed
on the device.
I presume that if you wanted to compose a message in the built-in Mail app, you would use a mailto: URL. Not sure about opening an existing message. And if you want to open an existing message in another app, then that app would need to define a custom URL scheme, and you'd need to use that.

I am not able add a link to open my iphone app

What I am trying to do is, Send user a link in email, and then when user taps on the link. My iOS app should open.
I am giving:
<a href = "myappNAME://profile">
The issue I have been facing that the email link is not even clickable.
I also completed the ios side as well. followed this link
http://skookum.com/blog/open-an-ios-app-from-an-email
Here is how you can do it open your project plist and add a url type(See screenshot).Fill in the required information identifier should be your bundle identifier and for url scheme just put a string say "hello".Build the app,than go to safari and type hello:// this should open the App.And for the link in email should have this scheme and it will open the App.
The reason was email filters, they disable the links like "myapp://" .
So what I have to do is, add a link to another page and from their I added a redirect, and then It worked.

How do I get mailto links in iOS (safari) to open the Outlook app?

I've noticed that on iPhone users who are using the Outlook app and do not have the native mail app configured, that when they click on mailto links it prompts them to create a new email account in iOS, instead of opening the Outlook app.
Is there anyway to have Outlook set as the default for mailto links on the iPhone?
iOS doesn't currently support changing the default apps used for composing email and the like.
Instead of 'mailto:' protocol you can use below protocol to open outlook app
ms-outlook://compose?to=joe#example.com&subject=Hello
Duplicate, Already solved here: https://stackoverflow.com/a/33812714/1360730
To test try typing
ms-outlook://compose?to=a#a.com&subject=aaaa in the address bar on safari and see whether the outlook app opens up.
So your href would look something like,
<a href="ms-outlook://compose?to=a#a.com&subject=aaaa"/>
From the upcoming iOS 14 on, this will be an option that users can set.
Set default email and browser apps.
With iOS 14, you can set a third‑party app as the default email or browser app systemwide.
Source: https://www.apple.com/ios/ios-14-preview/

Launch App from eMail with URL-Sheme

Hello I have a custom URL to open an app with a link. It works in the browser. But I want to send an email that another user can click the link in the email and the app will be started. Does anybody know a solution?
It is not possible to send an email with the link (myApp://). It always shows the the link as blank text.
Or does anyone know another solution to transfer data between an app to a other users app?
I think you need to write the link in href html tag
i.e. open my app
another solution is to try to add any text after the double slash i.e. myApp://open

Is there a way to intercept URLs so they are opened in my app

Is there a way to intercept URLs on iOS (iphone/iPad) such that a URL from a specific host is always opened by my app and not by the browser?
Example: http://myapp.com/ref/123 -> gets opened by my app and I parse out the 123
Update
I find it really weird that this isn't allowed on iOS (iphone/ipad). On Android I've been able to intercept a url and whenever it begins with http://myapp... it gets opened in my app.
How does the community solve the issue of: Say a user who has my app installed on their iphone gets a link from a friend in an email. When they click it, if the link can't be opened in my app...how else am I suppose to do anything good with the shared url? OR should I not be passing http:// links but myapp:// instead??
The scheme name (or protocol) of a URL is the first part of a URL - e.g. schemename://. For web pages, the scheme is usually http (or https). The iPhone supports these URL schemes:
http, https, ftp Web links* (Safari)
mailto E-mail links (launches the Mail app)
tel Telephone Numbers (launches the phone app)
sms Text Messages (launches the SMS app)
iPhone apps can specify their own custom URL scheme (for example, myapp://doStuff). But it's not possible to redirect a specific http host to be opened by your app.
To add a custom URL scheme to your app follow this guide,
Custom URL schemes

Resources