有什么方法可以检查iOS设备上是否安装了“ Google Fit”应用?
我尝试过:
UIApplication.SharedApplication.CanOpenUrl(new NSUrl("FitApp://com.google.fit"));
这总是返回false
您需要在Info.plist的FitApp
数组中添加LSApplicationQueriesSchemes
(注意,没有冒号)。
然后,您可以在代码中检查是否可以打开FitBit:
-注意冒号
UIApplication.SharedApplication.CanOpenUrl(new NSUrl("FitApp:"));