requestLocation() errorCode 0

Hello,

I am trying to find addresses on Android, but always get errorCode 0 and no errorMessage. On iOS, it works fine. mapsKey is correct, and internet permission is being required.

Map calls like setRegion() or addMarker() also work fine.

code:

local function locationHandler(e) if (e.isError) then print("Map Error: " .. json.prettify(e)) else print("Map Location: " .. e.latitude .. "," .. e.longitude) end end map: requestLocation(e.target.text, locationHandler)

print:

12-18 16:22:14.271 30074 30460 I Corona  : Map Error: {

12-18 16:22:14.271 30074 30460 I Corona  :   “errorCode”:0,

12-18 16:22:14.271 30074 30460 I Corona  :   “errorMessage”:"",

12-18 16:22:14.271 30074 30460 I Corona  :   “isError”:true,

12-18 16:22:14.271 30074 30460 I Corona  :   “name”:“mapLocation”,

12-18 16:22:14.271 30074 30460 I Corona  :   “request”:“San Francisco”,

12-18 16:22:14.271 30074 30460 I Corona  :   “type”:“request”

12-18 16:22:14.271 30074 30460 I Corona  : }

Still no luck on this one. Any ideas?

@phillip3 I’m getting the same thing.  Here’s the event structure I get in my requestlocation handler:

 {

     [“type”] = “request”;

     [“name”] = “mapLocation”;

     [“request”] = “10800 Torre Ave, Cupertino, CA 95014”;"

     [“errorCode”] = 0;

     [“isError”] = true;

     [“errorMessage”] = “”;

 }

Of course, one should never get “no data” (i.e., no “latitude”, “longitude”) unless errorCode is non-0 and errorMessage is non-empty :slight_smile:

BTW, I also don’t get taps on the map, even though I’ve requested them like in the sample code :frowning:

(Yes, I have a Google Maps API key)

(Android, Samsung Galaxy S7 Edge;  Corona 2020.3575)

Stan