本文整理自网络,侵删。
function IOSGetDeviceID: string;
var
LDevice: UIDevice;
begin
Result := '';
LDevice := TUIDevice.Wrap(TUIDevice.OCClass.currentDevice);
if LDevice <> nil then
Result := NSStrToStr(LDevice.identifierForVendor.UUIDString);
end;
这个函数,在FMX.PushNotification.iOS单元中。
我也没用过,请教Aone,他说这个返回唯一值,但重装app后会变化。
真是麻烦事!
相关阅读 >>
Delphi winapi: gettickcount - 获取系统已启动的时间
Delphi10.3构造一个json数据的第二种方法,并格式化输出
Delphi2007-Delphi2010 程序不出现在任务栏的方法
Delphi comparedatetime、comparedate、comparetime、samedatetime、samedate、sametime �c 对比时间的函数
更多相关阅读请进入《Delphi》频道 >>