MKMapView userLocation 未显示在 ipod 中

发布于 2024-08-26 15:50:57 字数 153 浏览 4 评论 0原文

我用于

self.mapView.showsUserLocation = YES;

在 MKmapview 上显示蓝点(圆圈)。它在模拟器中工作正常。但当我在 iPod 中测试时,它没有显示。有人知道会是什么原因吗?提前致谢

i used

self.mapView.showsUserLocation = YES;

for showing blue dot (circle) on MKmapview. Its working fine in simulator. but when i tested in Ipod, its not showing. Anybody know what will be the reason ? thanks in advance

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

ゃ人海孤独症 2024-09-02 15:50:57

如果地图中也没有显示蓝色圆圈,则说明您的本地 wifi 网络不在系统中(在 iPod 上,您的位置由最近的 wifi ssid 确定)。有两种解决方案:将它们列出(不确定在哪里可以做到)或去某个有效的地方。在 iPhone 模拟器中,您会获得一个模拟位置,因此它的工作原理并不是那么有趣。

如果您在“地图”中看到蓝色圆圈,但在您的地图中没有看到,我们可以进一步查看。

If the blue circle doesn't show in Maps either, than your local wifi networks aren't in the system (on the iPod your locationis determined by the nearest wifi ssid's). Two solutions: get them listed (not sure where you can do that) or go somewhere where it does work. In the iPhone Simulator you get a simulated location, so not so interesting that it works.

If you get the blue circle in Maps but not in your map, we can look further at it.

你在看孤独的风景 2024-09-02 15:50:57

iPod 是否位于同一无线网络上且启用了定位服务?

Is the iPod on the same, wireless network with location services enabled?

漆黑的白昼 2024-09-02 15:50:57

检查你是否已经给了代表 --->map.delegate=SomeController;

-(void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFindPlacemark:(MKPlacemark *)placemark;

- (void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFailWithError:(NSError *)error;

Check if u have given the delegates --->map.delegate=SomeController;

-(void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFindPlacemark:(MKPlacemark *)placemark;

and

- (void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFailWithError:(NSError *)error;
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文