-1

I have an issue with huawei devices and all devices without google play services What should I do if I want to get user location from these devices?

Raana Yavari
  • 199
  • 1
  • 4

1 Answers1

1

You can use LocationManager with GPS or NETWORK provider.

LocationManager locationManager = (LocationManager) getApplicationContext().getSystemService(LOCATION_SERVICE);

Location location = locationManager.getLastKnownLocation(LocationManager.NETWORK_PROVIDER);

Reference: get location without google play services -android

Min Thura
  • 21
  • 2