core-telephony

iOS I can't get my carrier name

坚强是说给别人听的谎言 提交于 2019-12-03 03:39:12
as explained here -> Retrieving Carrier Name from iPhone Programmatically i'm trying to get my carrier's name, i'm using this code CTTelephonyNetworkInfo *netinfo = [[CTTelephonyNetworkInfo alloc] init]; CTCarrier *carrier = [netinfo subscriberCellularProvider]; NSLog(@"Carrier Name: %@", [carrier carrierName]); [netinfo release]; but i receive a warning on [carrier carrierName] : Instance method '-carrierName' not found i've added and the framework coretelephony to my project but when i execute my app it crashes! thanks to all! Did you explicitly import CTCarrier? #import <CoreTelephony

iPhone, call another phone number in response to the first not answering?

跟風遠走 提交于 2019-12-02 21:27:11
I am attempting to create an application that will initiate a call to a priority 1 contact on a call-center-like list. Then, if that contact does not answer (let's forget the whole problem of answering machines here), I'd like to call the priority 2 contact, and so on, until one of them answers or I exhaust my list. Is this possible? I've tried the following: Hook into the CTCallCenter.CallEventHandler event, and checking the call state for CTCallStateConnected and CTCallStateDisconnected , and I get it to respond to the fact that the call disconnected, without ever connecting, and then

Sending an iMessage as simple as possible iOS

末鹿安然 提交于 2019-12-02 17:45:31
I want to be able to programmatically send an iMessage without anything else being done except calling a function that will send a text to a number with a message, both of which are text boxes. I'd really appreciate some sample code as I've hunted the net but nothing I've found will help. This is not for a commercial app, just me so it can use Private frameworks, or anything that will do the job. Thanks. woz The only way to send a message is to the MessageUI framework. There is an example of how to do this in the iOS documentation: https://developer.apple.com/library/ios/#samplecode

iPhone sdk call interception

老子叫甜甜 提交于 2019-12-01 23:58:07
问题 We are developing a app .The function of the app is "when we got a call automatically we have to reply through text/voice message .So,can you tell us whether it possible in iPhone.If means guide us to build the app. Thanks in advance , BrightRaj 回答1: It is not possible to access the phone in such a way with the current SDK. I guess it can be done on a jailbroken iPhone or on the Android platform. 来源: https://stackoverflow.com/questions/4255205/iphone-sdk-call-interception

How to get incoming/outgoing call event in background state

心已入冬 提交于 2019-12-01 23:12:01
问题 In one of my app it has a feature of playing sound that I achieved successfully. Even though when app is running (foreground state) and we received the incoming call, app music gets stopped and resume again when call gets disconnected. Now real problem is here. When app enters in the background state, we are not receiving any event for incoming/outgoing call. In the background mode If music is playing inside my app and we get any incoming call, then app music is stopped automatically but not

iOS check if cellular technology available even if the device is on WiFi

女生的网名这么多〃 提交于 2019-12-01 22:15:50
问题 Need some help here. I need to detect if an iOS device have (on a certain moment) cellular capabilities (No matter which one). I tried to use reachability class, but the problem start when the user is connected to WiFi, because if so - reachability can't detect cellular I also tried to use this code: CTTelephonyNetworkInfo *telephonyInfo = [CTTelephonyNetworkInfo new]; NSLog(@"Current Radio Access Technology: %@", telephonyInfo.currentRadioAccessTechnology); [NSNotificationCenter

iPhone sdk call interception

China☆狼群 提交于 2019-12-01 21:32:40
We are developing a app .The function of the app is "when we got a call automatically we have to reply through text/voice message .So,can you tell us whether it possible in iPhone.If means guide us to build the app. Thanks in advance , BrightRaj It is not possible to access the phone in such a way with the current SDK. I guess it can be done on a jailbroken iPhone or on the Android platform. 来源: https://stackoverflow.com/questions/4255205/iphone-sdk-call-interception

How to get incoming/outgoing call event in background state

有些话、适合烂在心里 提交于 2019-12-01 20:55:17
In one of my app it has a feature of playing sound that I achieved successfully. Even though when app is running (foreground state) and we received the incoming call, app music gets stopped and resume again when call gets disconnected. Now real problem is here. When app enters in the background state, we are not receiving any event for incoming/outgoing call. In the background mode If music is playing inside my app and we get any incoming call, then app music is stopped automatically but not resume again when call disconnected unlike iPhone Music app. Is it a limitation of the iOS or can we

Detect phone calls on iOS with CTCallCenter (Swift)

萝らか妹 提交于 2019-12-01 04:03:14
I wanted to try to detect incoming phone calls in my app. I created a new Swift project from scratch just to try some code. The only thing I did was importing CoreTelephony in the ViewController that is created with every new project and I also changed the viewDidLoad() to: super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. let callCenter = CTCallCenter() NSLog("start") callCenter.callEventHandler = {[weak self] (call: CTCall) -> () in self?.label.text = call.callState NSLog("Call state") NSLog(call.callState) } I also tried without the [weak self]

Getting wrong carrier name in IOS

让人想犯罪 __ 提交于 2019-11-30 14:33:41
I am working on an IOS application.My requirement is to get the mobile carrier name.I used the following code. In .h #import <CoreTelephony/CTTelephonyNetworkInfo.h> #import <CoreTelephony/CTCarrier.h> In .m CTTelephonyNetworkInfo *netinfo = [[CTTelephonyNetworkInfo alloc] init]; CTCarrier *carrier = [netinfo subscriberCellularProvider]; NSLog(@"Carrier Name: %@", [carrier carrierName]); Here in Log its printing "Carrier" I googled and found this link .But as per its answer my device is still not in airplane mode and sim card exists inside.If any one worked on it,please help me.Its killing my