tags:

views:

1241

answers:

2

Does anyone know how I can get the phone number of the device I am developing on so that I may use it in my app?

+2  A: 

See this:

Getting the local iPhone number through SDK

Dana Holt
A: 

Here you can find how to get the iphone sim number as string

http://blog.timeister.com/2009/06/25/objective-c-get-iphone-number/

code:

NSString *num = [[NSUserDefaults standardUserDefaults] stringForKey:@”SBFormattedPhoneNumber”]; NSLog(@”Phone Number: %@”, num);

Adrian