Search code examples
androidfirebase-realtime-databasegeolocationlatitude-longitude

how to get live loccation using GeoQuery method in android firebase realtimeDatabase?


How to get current Live Location using GeoQuery Method from Firebase RealTime Database. Is working GeoQuery in Android Version 9.0 ?


Solution

  • Locations that are stored in the database are not necessarily related to the current location of the user/device.

    To get the latter, you'll want to look at the Android APIs to get a location, for example this documentation on getting the last known location and How do I get the current GPS location programmatically in Android?