开发者社区> 问答> 正文

iOS 怎样获取本机的电话号码

iOS 7怎样获取本机号码,不要求上传appstroe,纯粹自己想研究一下,能不能实现这个功能,CTSettingCopyMyPhoneNumber()这个方法也亲试,在ios 7上无效,请哪个热心的大神帮忙解惑一下,现在ios 倒底能不能获取本机的电话号码。(xcode 和模拟器都是最新版的 5.0.2和7.0)

展开
收起
杨冬芳 2016-06-29 18:21:13 5925 0
1 条回答
写回答
取消 提交回答
  • IT从业

    根据我找到的最新答案:
    "For security reasons, iPhone OS restricts an application (including its preferences and data) to a unique location in the file system. This restriction is part of the security feature known as the application's "sandbox." The sandbox is a set of fine-grained controls limiting an application's access to files, preferences, network resources, hardware, and so on." The device's phone number is not available within your application's container.

    2019-07-17 19:49:19
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
手淘iOS性能优化探索 立即下载
From Java/Android to Swift iOS 立即下载
深入剖析iOS性能优化 立即下载