0

I want to make a button where, when pushed, the user's native gps application opens up with the address already put in for the "to" field.

I can do something similar with the telephone dialer this way:

// ---------------------- CALL SOMEONE! ------------
const callURL:String="tel:6094329861";  
var targetURL:URLRequest = new URLRequest(callURL);
navigateToURL(targetURL);
// ------------------------------------------------------
Jim
  • 3,821
  • 1
  • 28
  • 60
  • Check out http://stackoverflow.com/questions/10769631/is-there-a-map-uri-prefix-to-launch-map-application-like-mailto-or-tel – James Mar 14 '13 at 12:56

1 Answers1

0

you can do it by navigateToURL() and the user will be asked if he wants to open in broweser or app.

var long:Number = destinationLong;
var lat:Number = destinationLat;
navigateToURL(new URLRequest("http://maps.google.com/?q="+String(lat)+","+String(long)));
M4tchB0X3r
  • 1,531
  • 1
  • 15
  • 28