iOS7 app backward compatible with iOS5 regarding unique identifier

后端 未结 3 766
天命终不由人
天命终不由人 2020-12-06 02:35

My app is compatible with iOS5 and iOS6. Until now I had no problem using:

NSString DeviceID = [[UIDevice currentDevice] uniqueIdentifier];

3条回答
  •  眼角桃花
    2020-12-06 02:45

    As hard replacement of static macro, you can try dynamic if statement to check it.

    UIDevice has property named 'systemVersion' and you can check this.

提交回复
热议问题