How to get phone number of incoming call in iOS Swift?
I want to fetch phone number of incoming caller in my app.
Please someone provide me solution of this problem in swift.
- Swift 2 array of tuples not working as in swift 1
- Use of unresolved identifier GGLContext and GAI
- Swift 2.0 replicate OBJC_ASSOCIATION_RETAIN
- Downcast from UITabBarItem? to UITabBarItem only unwraps optionals; did you mean to use '!'
- How to make Playground execution time is as fast as if we run in iOS application
2 Solutions Collect From Internet About “How to get phone number of incoming call in iOS Swift?”
You will never be able to get the phone number of the incoming call since this is users private data, Apple will not allow you to acces the data.Its strictly restricted by Apple
Check out Core Telephony Framework: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CoreTelephonyFrameworkReference/index.html
There is CTCall method, But CTCall identifying the call will only tell you the cureent state of call i.e is call being accepted or rejected. The callID of CTCall will just give you an unique identifier for that call but not the number being called.
NOTE your app should be in foreground state, otherwise it will not work.
- UILabel is not auto-shrinking text to fit label size
- Embedded fonts in iOS: why are they not centered correctly on the y axis?
- No “show” in the segue action list in Xcode 6.1
- How do I set a property on a custom view instantiated from a XIB
- Formatting floats in Objective C
- Ionic splash screen not loading
- Showing a modal NSWindow, without activating the other application windows
- How to draw a route between my current location to desired location on MKMapView?
- Group table view background color is deprecated in ios 6.0
- How to tell with Objective-C if the iPhone is connected to a wifi network?
- How can I add CGPoint objects to an NSArray the easy way?
- iPhone AVPlayer Streaming from Remote URL in PhoneGap
- UIButton title not displaying
- How to change a UISlider value using a single touch?
- Why are doubles printed differently in dictionaries?