i want to find latitude and longitude of user current position and insert in db every second. and drawer a path according to all latitude and longitude of user move on location without using GPS
Asked
Active
Viewed 380 times
-4
-
2without GPS you cannot get user exact location. if you not want to turn on GPS then use Network Provider for get user location but its not user accurate location. – Hitesh Gehlot Apr 06 '17 at 11:56
-
If you do not want to use gps then what do you want to use? – greenapps Apr 06 '17 at 12:32
2 Answers
0
If you don't want to use GPS you can use services which use WLAN, Bluetooth or CellTower information to determine the position of a device. For Example the Mozilla Location Service.

IIIIIIIIIIIIIIIIIIIIII
- 3,958
- 5
- 45
- 70
0
Only way how you can do it is position based on mobile signal strength https://developer.android.com/guide/topics/location/strategies.html but this methode is not very accurate. Don´t forget on permission in manifest :
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
Then just register a listener and get the updates
LocationManager manager = (LocationManager)
context.getSystemService(Context.LOCATION_SERVICE);
manager.requestLocationUpdates(
LocationManager.NETWORK_PROVIDER, 1, 10, listener);

JakSok
- 124
- 4
-
i already try to using network provider and location service but find wrong latitude and longitude – Bhavesh Patel Apr 06 '17 at 12:18
-
This metode is not very accurate but is it only way how to locate device without GPS – JakSok Apr 06 '17 at 14:15