7

UIDevice.current.name it's worked if used iOS15, but when I tested on iOS16 (beta3) still return 'iPad' name all the time.

See related WWDC 2022 video file

  1. https://developer.apple.com/videos/play/wwdc2022/10096/
  2. https://developers.apple.com/videos/play/wwdc2022/10068/

I used:

  • iPadOS (iOS16 beta3)
  • Xcode (Version 14.0 beta 3 (14A5270f))

I added on entitlement, but it's don't work enter image description here

Uthen
  • 627
  • 2
  • 9
  • 17
  • Why does anyone needs to `see related WWDC 2022 video file`? Is there any specific info there which you wanted to emphasise? – olha Jul 14 '22 at 15:48
  • reviews on first video file (track: 0:03:11 - 0:03:50) on "UIDevice.name requires the entitlement com.apple.developer.device-information.user-assigned-device-name" – Uthen Jul 14 '22 at 15:51
  • and reviews on second video file (track 0:23:03) – Uthen Jul 14 '22 at 15:55
  • So have you added that entitlement? – olha Jul 14 '22 at 15:56
  • I guess the actual question you want to ask here: _How do I get that entitlement_, right? Well, [Apple hasn't told us yet](https://developer.apple.com/forums/thread/708275)! So please file a Feedback with Apple. – DarkDust Jul 14 '22 at 15:57
  • yes, try to added entitlement file, but still don't work, when I debug device name still show 'iPad' – Uthen Jul 14 '22 at 16:01
  • That's not how you add an entitlement. You need to [modify your `Entitlements.plist`](https://stackoverflow.com/questions/19674514/how-to-create-entitlement-plist-file-in-xcode). – DarkDust Jul 14 '22 at 16:18
  • Thank you, I added an entitlement file, but don't have any information on dropdown list for about device name. – Uthen Jul 14 '22 at 16:55
  • Please any new information about this entitlements – Hichem Romdhane Jul 21 '22 at 15:21
  • 1
    On iOS16 beta 4 : apple updated some document file : https://developer.apple.com/documentation/bundleresources/entitlements/com_apple_developer_device-information_user-assigned-device-name – Uthen Aug 05 '22 at 15:40
  • @Uthen do you fixed this problem if yes please can you share that – Hichem Romdhane Aug 08 '22 at 14:08
  • 2
    We can't fix the problem under Apple enterprise account program, we send request to apple team reviews and wait feedback. – Uthen Aug 09 '22 at 01:41
  • 2
    Now it's worked apple approved i can access to User Assigned Device Name Entitlement web site (under apple enterprise account). Contact to apple team and they will be help you. @HichemRomdhane – Uthen Aug 18 '22 at 15:36
  • 2
    Now it's fixed >> step 1) approve from apple 2) change certificate to support on this feature 3) add file entitlements on iOS project. – Uthen Sep 15 '22 at 08:58
  • revision from @uthen – Idelfonso Gutierrez Dec 14 '22 at 16:42

1 Answers1

8

revision on what @uthen mentions

You should

  • The account owner must fill up the request on User-Device User-Device
  • Enable the "additional capabilities" in Developer Portal > IDentifiers > {App Id} > additional capabilities
  • Generate new provisioning profile for development and AppStore
  • if you don't have it "add a new file" property list, rename the file extension to .entitlements set the environment in the Build Settings CODE SIGNING ENTITLEMENTS top the path where the [name].entitlements file is located.
  • in the entitlements file add a new empty entry and set the key to com.apple.developer.device-information.user-assigned-device-name, the type to Boolean and the value to true