I need to access location in the background when my app is running.
I successfully received location updates when my main activity implemented android.location.LocationListener
if (ActivityCompat.checkSelfPermission(this,…
"I need to switch Base URL based on a user's Location and change other UI components".
I tried throughout the Build Config but I didn't find anything that seems to work.
My app requires users to be tracked at regular intervals.
this is my location service class intended to provide location updates in the set interval. this code works fine until Nougat but doesn't work from Oreo. this code was working fine a few days…
I am using FusedLocationClient for the location. I have noticed that some times it takes too much time for onLocationChanged() to get called because of whatever issues. Is there any good way that i can put a timer on that, for example if i don't get…
I don't understand how geofencing can be more accurate than checking location at regular intervals (https://codelabs.developers.google.com/codelabs/background-location-updates-android-o/index.html?index=..%2F..%2Findex#6) ? Because let say I m at…
I'm trying to access the location and display the latitude and longitude in textviews onClick of a button.
Here's my code:
import android.Manifest;
import android.app.Activity;
import android.content.Context;
import…
I have a Started service called LocationService, which retrieves the location of the device every 3 seconds. I would like these values to be displayed on the UI of the application. To do so I would need to pass values back to the Main Activity.
The…
I have no idea how to save location in Firebase without using Geofire. One possible method may be to save only the co-ordinates to Firebase but looking at the location object (of Android), it has so many properties along with the coordinates. How to…
Hey friends i am showing the path as user(smartphone) moves from one location to another in my app. I want to store that path till user explicitly clears it .
when I close the application the drawn path gets removed from the map. I want to save that…
I am trying to build an app from here, where the user clicks on a button and get the current latitude and longitude but the problem is that I am getting 0.0 for both latitude and longitude. I have one activity and one service in my application. The…
I want turn on gps automaticly when my application starts, like another applications. I have the below code:
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
…
I get duplicate data items in the recyclerview after the location data has been updated
I have tried some such like way
NotifyDataSetChanged () and setHasStableIds (true)
But still has not succeeded
public class FragmentPetaniTerdekat extends…
I have generated Current location value and i am passing it to the URL dynamically. I am getting value of Latitude and 'Longitude' in my Logcat. but dynamic URl for LatLongUrl is not generated…
How to find the distance between two locations on android ecillipse project &php .the project is based on online good transport system .The fare of the carrier needed to be found out so there is a need of finding distance between source &…
For using the android location based services we use the GPS tracker class which extends Service and implements LocationListener interface. What is the use of Service class here ? Is it only for getting the location updates in the background or…