[android-developers] Re: Launch navigation app with an Intent - [DS]

2012-08-12 Thread NayAnesh Gupte


You could use something like this:

Intent intent = new Intent(android.content.Intent.ACTION_VIEW, 
Uri.parse(http://maps.google.com/maps?saddr=20.344,34.34daddr=20.5666,45.345;));
startActivity(intent);

You can use an actual street address instead of latitude and longitude. 
However this will give the user a dialog to choose between opening it via 
browser or Google Maps.

If you are in the US, you could use an unofficial way (Since it isn't 
official, I don't recommend using it). This will fire up Google Maps in 
navigation mode. Haven't played with it since where I live it isn't 
available.

Intent intent = new Intent(android.content.Intent.ACTION_VIEW,
Uri.parse(google.navigation:q=an+address+city);



If you want to get rid of the dialog you can give the intent a hint as to 
which package you want to use. 
Before the startActivity() add this: 
intent.setClassName(com.google.android.apps.maps, 
com.google.android.maps.MapsActivity); 


On Saturday, December 12, 2009 3:18:20 AM UTC+5:30, Declan Shanaghy wrote:

 Hello,
 I realize this might not be the proper place to post this since it's not 
 Android specific, but rather its about integrating with a google app.

 I've been trying to find some documentation on launching / controlling the 
 Google Navigation app via Intents or otherwise.
 I was hoping to find an intent to launch the navigation app with address 
 parameters setup and start navigation immediately.

 Can't find anything out there, so I'm still not even sure if it can be 
 done.

 Anyone have any ideas?


 Thanks,
 Dek


 -- 
 An engineer's definition of done is the perfect set of code, and left to 
 his own devices, an engineer will endlessly improve the code on the mythic 
 journey to done.
 -- http://www.randsinrepose.com

 [DS]



-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Launch navigation app with an Intent - [DS]

2010-01-04 Thread Declan Shanaghy
This code will work on any SDK.
What matters here is the version of google maps that is on the device.

The navigation features were added in google maps version 3.2.1 as far as i
know.



On Sun, Jan 3, 2010 at 9:28 AM, kautilya imtheno...@gmail.com wrote:

 Hi Declan ,

 Thanks for your code . it's working very well But only with SDK 2.0.1.

 Thanks
 kautilya

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
An engineer's definition of done is the perfect set of code, and left to
his own devices, an engineer will endlessly improve the code on the mythic
journey to done.
-- http://www.randsinrepose.com

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Launch navigation app with an Intent - [DS]

2010-01-03 Thread kautilya
code  working very smoothly on SDK 2.0.1

Intent i = new Intent(Intent.ACTION_VIEW,
Uri.parse(google.navigation:q=New+York+NY));
startActivity(i);

Thanks Declan .

On Dec 18 2009, 1:39 am, Declan Shanaghy dec...@350nice.com wrote:
 Sorry but that's just a web URL, not the Navigation App.

 I found out how to do it by applying a bit of guesswork after reading this
 page (suggested previously by Lance, thanks 
 Lance)http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents

 Intent i = new Intent(Intent.ACTION_VIEW,
 Uri.parse(google.navigation:q=New+York+NY));
 startActivity(i);



 On Wed, Dec 16, 2009 at 11:45 PM, lk vaish.alo...@gmail.com wrote:
  for opening in navigation mode try this--
  Intent navigation = new Intent(Intent.ACTION_VIEW, Uri.parse(“http://
  maps.google.com/maps?
  saddr=42.35892,-71.05781daddr=40.756054,-73.986951http://maps.google.com/maps?%0Asaddr=42.35892,-71.05781daddr=40.7560...
  ”));
  startActivity(navigation);

  where saddr = latitude and longitude of starting point.
  and   daddr = latitude and longitude of destination point.

  thanks

  On Dec 12, 10:57 am, Declan Shanaghy dec...@350nice.com wrote:
   Well yes it is the maps app but i want to launch in in Navigation mode,
  not
   just a plain ole map.
   This is for a Droid specific app, which has Android 2.0 with Google
   Navigation.

   On Fri, Dec 11, 2009 at 4:37 PM, Lance Nanek lna...@gmail.com wrote:
Do you mean the Google Maps app? For that you can use an intent with
an ACTION_VIEW action and URI like this:
geo:0,0?q=my+street+address

Documented on this page:
   http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents..
  ..

On Dec 11, 4:48 pm, Declan Shanaghy dec...@350nice.com wrote:
 Hello,
 I realize this might not be the proper place to post this since it's
  not
 Android specific, but rather its about integrating with a google app.

 I've been trying to find some documentation on launching /
  controlling
the
 Google Navigation app via Intents or otherwise.
 I was hoping to find an intent to launch the navigation app with
  address
 parameters setup and start navigation immediately.

 Can't find anything out there, so I'm still not even sure if it can
  be
done.

 Anyone have any ideas?

 Thanks,
 Dek

 --
 An engineer's definition of done is the perfect set of code, and
  left to
 his own devices, an engineer will endlessly improve the code on the
mythic
 journey to done.
 --http://www.randsinrepose.com

 [DS]

--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to
  android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com

For more options, visit this group at
   http://groups.google.com/group/android-developers?hl=en

   --
   An engineer's definition of done is the perfect set of code, and left to
   his own devices, an engineer will endlessly improve the code on the
  mythic
   journey to done.
   --http://www.randsinrepose.com

  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en

 --
 An engineer's definition of done is the perfect set of code, and left to
 his own devices, an engineer will endlessly improve the code on the mythic
 journey to done.
 --http://www.randsinrepose.com

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Launch navigation app with an Intent - [DS]

2010-01-03 Thread kautilya
Hi Declan ,

Thanks for your code . it's working very well But only with SDK 2.0.1.

Thanks
kautilya

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Launch navigation app with an Intent - [DS]

2009-12-17 Thread Declan Shanaghy
Sorry but that's just a web URL, not the Navigation App.

I found out how to do it by applying a bit of guesswork after reading this
page (suggested previously by Lance, thanks Lance)
http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents.html


Intent i = new Intent(Intent.ACTION_VIEW,
Uri.parse(google.navigation:q=New+York+NY));
startActivity(i);



On Wed, Dec 16, 2009 at 11:45 PM, lk vaish.alo...@gmail.com wrote:

 for opening in navigation mode try this--
 Intent navigation = new Intent(Intent.ACTION_VIEW, Uri.parse(“http://
 maps.google.com/maps?
 saddr=42.35892,-71.05781daddr=40.756054,-73.986951http://maps.google.com/maps?%0Asaddr=42.35892,-71.05781daddr=40.756054,-73.986951
 ”));
 startActivity(navigation);

 where saddr = latitude and longitude of starting point.
 and   daddr = latitude and longitude of destination point.


 thanks

 On Dec 12, 10:57 am, Declan Shanaghy dec...@350nice.com wrote:
  Well yes it is the maps app but i want to launch in in Navigation mode,
 not
  just a plain ole map.
  This is for a Droid specific app, which has Android 2.0 with Google
  Navigation.
 
 
 
  On Fri, Dec 11, 2009 at 4:37 PM, Lance Nanek lna...@gmail.com wrote:
   Do you mean the Google Maps app? For that you can use an intent with
   an ACTION_VIEW action and URI like this:
   geo:0,0?q=my+street+address
 
   Documented on this page:
  http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents..
 ..
 
   On Dec 11, 4:48 pm, Declan Shanaghy dec...@350nice.com wrote:
Hello,
I realize this might not be the proper place to post this since it's
 not
Android specific, but rather its about integrating with a google app.
 
I've been trying to find some documentation on launching /
 controlling
   the
Google Navigation app via Intents or otherwise.
I was hoping to find an intent to launch the navigation app with
 address
parameters setup and start navigation immediately.
 
Can't find anything out there, so I'm still not even sure if it can
 be
   done.
 
Anyone have any ideas?
 
Thanks,
Dek
 
--
An engineer's definition of done is the perfect set of code, and
 left to
his own devices, an engineer will endlessly improve the code on the
   mythic
journey to done.
--http://www.randsinrepose.com
 
[DS]
 
   --
   You received this message because you are subscribed to the Google
   Groups Android Developers group.
   To post to this group, send email to
 android-developers@googlegroups.com
   To unsubscribe from this group, send email to
   android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com
 
   For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en
 
  --
  An engineer's definition of done is the perfect set of code, and left to
  his own devices, an engineer will endlessly improve the code on the
 mythic
  journey to done.
  --http://www.randsinrepose.com

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
An engineer's definition of done is the perfect set of code, and left to
his own devices, an engineer will endlessly improve the code on the mythic
journey to done.
-- http://www.randsinrepose.com

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Launch navigation app with an Intent - [DS]

2009-12-16 Thread lk
for opening in navigation mode try this--
Intent navigation = new Intent(Intent.ACTION_VIEW, Uri.parse(“http://
maps.google.com/maps?
saddr=42.35892,-71.05781daddr=40.756054,-73.986951”));
startActivity(navigation);

where saddr = latitude and longitude of starting point.
and   daddr = latitude and longitude of destination point.


thanks

On Dec 12, 10:57 am, Declan Shanaghy dec...@350nice.com wrote:
 Well yes it is the maps app but i want to launch in in Navigation mode, not
 just a plain ole map.
 This is for a Droid specific app, which has Android 2.0 with Google
 Navigation.



 On Fri, Dec 11, 2009 at 4:37 PM, Lance Nanek lna...@gmail.com wrote:
  Do you mean the Google Maps app? For that you can use an intent with
  an ACTION_VIEW action and URI like this:
  geo:0,0?q=my+street+address

  Documented on this page:
 http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents

  On Dec 11, 4:48 pm, Declan Shanaghy dec...@350nice.com wrote:
   Hello,
   I realize this might not be the proper place to post this since it's not
   Android specific, but rather its about integrating with a google app.

   I've been trying to find some documentation on launching / controlling
  the
   Google Navigation app via Intents or otherwise.
   I was hoping to find an intent to launch the navigation app with address
   parameters setup and start navigation immediately.

   Can't find anything out there, so I'm still not even sure if it can be
  done.

   Anyone have any ideas?

   Thanks,
   Dek

   --
   An engineer's definition of done is the perfect set of code, and left to
   his own devices, an engineer will endlessly improve the code on the
  mythic
   journey to done.
   --http://www.randsinrepose.com

   [DS]

  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en

 --
 An engineer's definition of done is the perfect set of code, and left to
 his own devices, an engineer will endlessly improve the code on the mythic
 journey to done.
 --http://www.randsinrepose.com

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Launch navigation app with an Intent - [DS]

2009-12-11 Thread Lance Nanek
Do you mean the Google Maps app? For that you can use an intent with
an ACTION_VIEW action and URI like this:
geo:0,0?q=my+street+address

Documented on this page:
http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents.html

On Dec 11, 4:48 pm, Declan Shanaghy dec...@350nice.com wrote:
 Hello,
 I realize this might not be the proper place to post this since it's not
 Android specific, but rather its about integrating with a google app.

 I've been trying to find some documentation on launching / controlling the
 Google Navigation app via Intents or otherwise.
 I was hoping to find an intent to launch the navigation app with address
 parameters setup and start navigation immediately.

 Can't find anything out there, so I'm still not even sure if it can be done.

 Anyone have any ideas?

 Thanks,
 Dek

 --
 An engineer's definition of done is the perfect set of code, and left to
 his own devices, an engineer will endlessly improve the code on the mythic
 journey to done.
 --http://www.randsinrepose.com

 [DS]

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Launch navigation app with an Intent - [DS]

2009-12-11 Thread Declan Shanaghy
Well yes it is the maps app but i want to launch in in Navigation mode, not
just a plain ole map.
This is for a Droid specific app, which has Android 2.0 with Google
Navigation.




On Fri, Dec 11, 2009 at 4:37 PM, Lance Nanek lna...@gmail.com wrote:

 Do you mean the Google Maps app? For that you can use an intent with
 an ACTION_VIEW action and URI like this:
 geo:0,0?q=my+street+address

 Documented on this page:
 http://developer.android.com/intl/zh-CN/guide/appendix/g-app-intents.html

 On Dec 11, 4:48 pm, Declan Shanaghy dec...@350nice.com wrote:
  Hello,
  I realize this might not be the proper place to post this since it's not
  Android specific, but rather its about integrating with a google app.
 
  I've been trying to find some documentation on launching / controlling
 the
  Google Navigation app via Intents or otherwise.
  I was hoping to find an intent to launch the navigation app with address
  parameters setup and start navigation immediately.
 
  Can't find anything out there, so I'm still not even sure if it can be
 done.
 
  Anyone have any ideas?
 
  Thanks,
  Dek
 
  --
  An engineer's definition of done is the perfect set of code, and left to
  his own devices, an engineer will endlessly improve the code on the
 mythic
  journey to done.
  --http://www.randsinrepose.com
 
  [DS]

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
An engineer's definition of done is the perfect set of code, and left to
his own devices, an engineer will endlessly improve the code on the mythic
journey to done.
-- http://www.randsinrepose.com

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en