system.openURL("tel:") Doesn't Work on Android

Hi,

I'm having a problem with my application. I assign an event listener to an image, and when the user taps the image, it is supposed to open up a telephone number. Unfortunately, tel: doesn't work and wont open up the dialer on Android. Anyone know why?

system.openURL("tel:408-555-5555")

Regards,
Jordan Schuetz
Ninja Pig Studios

Just a quick way to get around the Corona issue. Instead, make the tel: link a TinyURL and call the TinyURL instead of the tel: command straight from Corona.

Remove the dashes from the phone number. That should make it work.

Actually Josh, that doesn't work. I thought the same thing you did, but when I tried it, it was unsuccessful.

Regards,
Jordan Schuetz
Ninja Pig Studios

Did you give your app permission to make a phone call? You can do so via the build.settings file as follows...

1
2
3
4
5
6
7
settings =
{
        androidPermissions =
        {
                "android.permission.CALL_PHONE",
        },
}

No I did not. I guess that was the issue. Whoops! The application is already published so I'll have to add that in a future update.

Heres the link: https://market.android.com/details?id=com.ninjapigstudios.weirdstuff

Regards,
Jordan Schuetz
Ninja Pig Studios

views:1887 update:2012/1/10 9:16:25
corona forums © 2003-2011