Search code examples
iosswiftphone-callopenurl

confirmation dialogue is not showing when making a phone call in ios 10.2.1 but showing in 10.3


I am using this code to make a phone call. But confirmation alert is not showing in the device which have iOS version 10.2.1 but showing in iOS 10.3.

if let url = URL(string: "tel://\(selectedNumber)"){
    if #available(iOS 10.0, *) {
        UIApplication.shared.open(url, options: [:], completionHandler: nil)
    } else {
        UIApplication.shared.openURL(url)                
    }
}
}

But i want to show the confirmation alert in all of the iOS version .


Solution

  • i have found the solution if i use "telprompt://" it shows confirmation dialogue i in all kinds of ios version. but in ios 10.3 confirmation dialogue shows if use "tel://" or "telprompt://".