开发者

How to display iphone version,IOS version,name of the the Network Provider in my app?

I am developing an iPhone app. In its about page I want to display the iPhone version, iOS version, and the name of the the Network Provider. I want fetch these from开发者_高级运维 the phone itself. How would I do that? Please Help.

Thanks in advance.


Model Version:

NSString *model = [[UIDevice currentDevice] model];

iOS Version:

NSString *systemVersion = [[UIDevice currentDevice] systemVersion];

Carrier name (iOS 4.0 minimum):

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

CTTelephonyNetworkInfo *netInfo = [[CTTelephonyNetworkInfo alloc] init];
CTCarrier *carrier = [netInfo subscriberCellularProvider];
NSString *carrierName = [carrier carrierName];
[netInfo release];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜