Getting the local iPhone number through SDK

前端 未结 4 1150
没有蜡笔的小新
没有蜡笔的小新 2020-12-10 00:31

I am looking for a SDK API to retrieve the device\'s local phone number
from the SIM card. Is there a way to do it?

4条回答
  •  Happy的楠姐
    2020-12-10 00:44

    Take a look at this blog post here.

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

    Adrian

提交回复
热议问题