location-samples icon indicating copy to clipboard operation
location-samples copied to clipboard

In LocationUpdates using Foreground sample gets NullPointerException: Attempt to invoke virtual method

Open ahmadmust8 opened this issue 8 years ago • 4 comments

in onStart() method calls mService.requestLocationUpdates() it's returns java.lang.NullPointerException: Attempt to invoke virtual method 'void <package_name>.LocationUpdatesService.requestLocationUpdates()' on a null object reference how can i get reference for LocationUpdatesService class ?

ahmadmust8 avatar May 02 '17 00:05 ahmadmust8

Have you defined the service in manifest?

bbeckk avatar Jan 22 '19 09:01 bbeckk

I'm too getting the same issue, I have service in Androidmanifest.xml file. Min API is 21 and target API is 28. Please help.

myselfsufiyan avatar Feb 28 '19 08:02 myselfsufiyan

Even i am facing the same issue please help!!

anujpanveli avatar Sep 04 '19 07:09 anujpanveli

Even i am facing the same issue please help!!

SumitShukla007 avatar Sep 17 '19 12:09 SumitShukla007