cjlotz / Xamarin.Plugins

Cross platform Xamarin Plugins
MIT License
113 stars 56 forks source link

Cannot work on IOS #98

Closed TianyiChen-1 closed 6 years ago

TianyiChen-1 commented 6 years ago

If you are creating an issue for a BUG please fill out this information. If you are asking a question or requesting a feature you can delete the sections below.

Failure to fill out this information will result in this issue being closed. If you post a full stack trace in a bug it will be closed, please post it to http://gist.github.com and then post the link here.

Bug Information

canOpenURL: failed for URL: "tel:0000000000" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" Version Number of Plugin: 5.20 Device Tested On: n/a Simulator Tested On: iphone simulator ios 11.2

Version of VS: vs2017 15.6.5 Version of Xamarin: 2.5.1.444934 Versions of other things you are using: n/a

Steps to reproduce the Behavior

phoneNumber.Clicked += (sender, e) => { Console.WriteLine("Pressed"); var PhoneCallTask = CrossMessaging.Current.PhoneDialer; if (PhoneCallTask.CanMakePhoneCall) PhoneCallTask.MakePhoneCall("+862368629315");

        };

Just create any button and add this event handler

Expected Behavior

I expect the iphone go to the dial number view

Actual Behavior

No transition happens

Code snippet

Screenshots

20180409214341

cjlotz commented 6 years ago

Phone calls are not supported on the iOS Simulators. You need to use a real device.