IllegalArgumentException thrown by requestLocationUpdate()

强颜欢笑 提交于 2019-11-29 09:54:34

I think this may be an issue with the Android Emulator at present.

See http://code.google.com/p/android/issues/detail?id=21237

zums
locationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 300000, 500, locationListener);

In your code use this LocationManager.NETWORK_PROVIDER when you testing that make sure that the network you are using like WIFI is available or you are inserted sim card in your device and network is available on it.

You may also test using LocationManager.GPS_PROVIDER but make sure before use that GPS is ON of device

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!