Titanium JIRA Archive
Appcelerator Community (AC)

[AC-6197] Titanium.Geolocation.getCurrentPosition is giving error

GitHub Issuen/a
TypeBug
Priorityn/a
StatusResolved
ResolutionNeeds more info
Resolution Date2019-04-22T22:28:08.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
Labelsandroid
Reporterpravsrivastava
AssigneeShak Hossain
Created2019-04-04T16:47:07.000+0000
Updated2019-04-22T22:28:08.000+0000

Description

I am developing an app with the geolocation services and there is no problem with iOS, however when I try to test it on Android, a location error occurs. [ERROR] : GeolocationModule: (main) [39266,89619] Unable to get current position, location is null I am using SDK 7.5.0GA and Android Samsung Galaxy S7 (8.0)

Comments

  1. Jebun Naher 2019-04-05

    Hi [~pravsrivastava], please try to build your project with latest ti sdk 8.0.0.GA which can be downloaded with the command: appc ti sdk install latest Let us know if you still experience the same in latest builds. Thanks!
  2. Rene Pot 2019-04-08

    getCurrentLocation returns a cached location. If you have not monitored for location yet you will not get a location. Use Ti.Gelocation location event to start monitoring for the location. See docs: https://docs.appcelerator.com/platform/latest/#!/api/Titanium.Geolocation-event-location Also, include ti.playservices module to enable better geolocation support
  3. Sharif AbuDarda 2019-04-09

    Hello [~pravsrivastava], did you followed Rene's guide above? let us know how things going.
  4. Rakhi Mitro 2019-04-21

    Hello, Did you able to find this issue resolved ? Let us know the current status of your issue whether the provided workaround was helpful or not. 

JSON Source