Home > Back-end >  Cannot find 'UIDevice' in scope
Cannot find 'UIDevice' in scope

Time:07-12

I want to get the Device Id of my device and I read about UIDevice but for some reason it's not working in my project, even if I import UIKit. Maybe someone knows why? Thanks in advance. enter image description here

CodePudding user response:

UIDevice is not available on Apple Watch. https://developer.apple.com/documentation/uikit/uidevice

Please check this: https://developer.apple.com/forums/thread/25529 There's WKInterfaceDevice for Watches.

  • Related