0

I am trying to open compose mail page of native default app in ios using flutter app but unable to do it. It shows me blank pop up window.

I have tried all kind of solution related to url_launcher but nothing is working for me.

enter image description here

Below is my code which i am using for opening native app from flutter app.

_sendingMails() async {
    const url = 'mailto:xyz@mail.com';
    if (await canLaunch(url)) {
      await launch(url);
    } else {
      throw 'Could not launch $url';
    }
  }

I have added url scheme as well in info.plist file.

<key>LSApplicationQueriesSchemes</key>  
<array>         
  <string>mailto</string>            
</array>

But still it gives me white pop up window in ios and in android its working fine.

  • Probably, links don't work on iOS simulators Here's [a link](https://stackoverflow.com/questions/42098235/trying-to-add-mailto-react-native) – Luis Pereira Aug 04 '22 at 16:07

1 Answers1

0

To send mail does not work in the 'simulator'.

Because the simulator does not provide default mail app.

Try it on a real device.

It'll work out.