Ozgur
Ozgur

Reputation: 1

Getting Carrier name in Cocoa Touch app

Is there a way to get the name of the current carrier of the phone inside a Cocoa Touch application?

Upvotes: 0

Views: 551

Answers (2)

Jalakoo
Jalakoo

Reputation: 3583

You can from iOS4+

First add the CoreTelephony.framework to your project.

Then import the following to the top of your .h or .m file:

#import <CoreTelephony/CTTelephonyNetworkInfo.h>
#import <CoreTelephony/CTCarrier.h>

Use sample:

CTTelephonyNetworkInfo *netinfo = [[CTTelephonyNetworkInfo alloc] init];
CTCarrier *carrier = [netinfo subscriberCellularProvider];
NSLog(@"Carrier name:%@", [carrier carrierName]);

Upvotes: 2

Jordan
Jordan

Reputation: 21760

The answers is No. Not officially. Not without Jailbreaking.

Upvotes: -1

Related Questions