Livecode地理位置没有返回结果
问题描述:
我创建了livecode样本栈测试geolocation
但不知何故,结果总是empty
Livecode地理位置没有返回结果
样品堆栈可以下载here
执行此代码:answer mobileCanTrackLocation()
将火true
mobileStartTrackingSensor "location", true
< - 开始追踪 mobileStopTrackingSensor "location"
< - 停止追踪
这是我在现场的结果显示代码:
get mobileSensorReading("location", true)
if it is an array then
combine it using return and "="
end if
put "Current Reading" && it & return before field "Result"
什么我错过了吗?
我使用Livecode 7.0.3
答
这为我工作可靠iOS上:
mobileStartTrackingSensor "location", false
put mobileSensorReading("location",false) into tData
mobileStopTrackingSensor "location"
不过,我一直无法得到它在Android设备上运行。将它作为LiveCode的一个错误报告可能会很好。
+0
谢谢@Devin。我会在iOS设备上进行验证。 – JunM 2015-04-06 01:38:01
你可以提供一些更多的信息。你在哪里测试你的应用程序?在模拟器中?在物理设备上?在什么样的设备上? – hliljegren 2015-04-01 17:57:03
@hliljegren我使用Android设备对其进行了测试。我还检查了权限设置的粗略位置和正确位置。另外我使用模拟器进行测试。 – JunM 2015-04-02 08:27:17