你好,歡迎來到IOS教程網

 Ios教程網 >> IOS編程開發 >> IOS開發綜合 >> [UIDevice uniqueGlobalDeviceIdentifier]: unrecognized selector sent to instance 0x6c29000

[UIDevice uniqueGlobalDeviceIdentifier]: unrecognized selector sent to instance 0x6c29000

編輯:IOS開發綜合
-[UIDevice uniqueGlobalDeviceIdentifier]: unrecognized selector sent to instance 0x6c29000  BaiduMapDemo[716:f803] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIDevice uniqueGlobalDeviceIdentifier]: unrecognized selector sent to instance 0x6c29000' *** First throw call stack: (0x15c1022 0x1b79cd6 0x15c2cbd 0x1527ed0 0x1527cb2 0xa747d 0x5fa4a 0x12508 0xee4b 0xefda 0x10b34 0x29c0 0x443386 0x444274 0x453183 0x453c38 0x447634 0x23f9ef5 0x1595195 0x14f9ff2 0x14f88da 0x14f7d84 0x14f7c9b 0x443c65 0x445626 0x28e8 0x2845) terminate called throwing an exception(gdb)  解決辦法: (1)運行報  [UIDevice uniqueGlobalDeviceIdentifier]: unrecognized selector sent to此時需要 other linker  flags 添加 -all_load參數。          具體:Project ->build settings ->linking->Other Linker flags (2)請檢查有沒有添加QuartzCore.framework 和 CoreLocation.framework 可能因為缺少這兩個框架中的某一個框架造成的錯誤。 (3)BMKMapManager 強烈建議通過單例模式管理起來,並且不要手動調用其release方法。 (4)進行用戶位置定位時除了要設置showsUserLocation = YES,還要在mapView:didUpdateUserLocation:方法中調用setCenterCoordinate:animated          另外一定要在dealloc中,或者其他離開頁面的地方調用showsUserLocation= NO,否則會出現第二次push到定位頁面時,不會重新定位問題。 (5)必須至少讓一個類保持.mm文件,或者按照官方修改編譯器類型。
  1. 上一頁:
  2. 下一頁:
蘋果刷機越獄教程| IOS教程問題解答| IOS技巧綜合| IOS7技巧| IOS8教程
Copyright © Ios教程網 All Rights Reserved