views:

281

answers:

3

Hey guys,

It is really frustrating me. I used the doc provided by Navigon itself. Unfortunately it doesn't work as expected. Navigon launches, but stops at the main menu.

All I do is this:

NSString *myTestStr = [NSString stringWithFormat:@"navigon://App|Another place|FRA|75008|PARIS|rue de Turin|17|2.324621|48.881273"];

   NSString *navigonStrEsc = [myTestStr stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
   NSLog(@"navigonStr: %@", navigonStrEsc);
   [[UIApplication sharedApplication] openURL:[NSURL URLWithString:navigonStrEsc]];

Any ideas what is wrong with my way?

thanks a lot!

A: 

hum it should work. Here's my code: The only diff is that my scheme changes if FRA is installed , then navigonFRA is prefered.

NSString* scheme = @"navigonFRA";
if ((![NavigonApplication isFRInstalled]) && [NavigonApplication isWorldInstalled])
    scheme = @"navigon";

NSString* urlAsString = nil;
urlAsString = [NSString stringWithFormat:@"%@://%@|%@|%@|%@|%@|%@|%@|%f|%f",
               scheme,
               @"myApp",            // Field1/AppName:Application or Company Name (e.g. AroundMe) 
               thePOI.name,         // Field2/NameOfPOI: Name of POI (e.g. Navigon AG Würzburg) 
               @"FRA",                  // Field3/Country: ISO 3166-1 alpha-3 code for country (http://unstats.un.org/unsd/methods/m49/m49alpha.htm) (e.g. DEU) 
               @"",                     // Field4/ZipCode: Postalcode, ZIP code of the POIs city (e.g. 97080) 
               thePOI.location.city,    // Field5/City: Name of POIs city (e.g. Würzburg) 
               thePOI.location.streetAddress,   // Field6/Street:POIs street name (e.g. Berliner Platz) 
               @"",                             // Field7/HouseNumber: POIs street/house number (e.g. 11) 
               thePOI.location.longitude,       // Field8/Longitude: Longitude in WGS84 (e.g. 9.870) 
               thePOI.location.latitude];       // Field9/Latitude: Latitude in WGS84 (e.g. 49.938) 

urlAsString = [urlAsString stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
NSLog(@"Starting Navigon app with %@", urlAsString);
NSURL*url = [[NSURL alloc] initWithString:urlAsString];
[[UIApplication sharedApplication ]openURL:url];
[url release];

And this code is working. Did you check that your navigon version is >= v1.5 ?

yonel
A: 

I have a similar issue, but with a html link. I used exactly the same link provided by the doc :

<a href="navigon://YourAppName%7CNice%20Place%7CDEU%7C97080%7CW%C3%BCrzburg%7CBerliner%20Platz%7C11%7C%7C">Click to navigate</a>

Navigon launches, but stops at the main menu too.

I tried several locations, with an iPhone and an iPad, but nothing worked.

I have the last version of Navigon MobileNavigator EU (1.5.1).

Thanks a lot for any help.

Matt

Matthieu
A: 

I found the problem, the first field (AppName) is pretty important.

The following html link now works :

<a href="navigon://Safari|Some nice place||||||9.937156|49.800074">Some nice place</a>

For informations : I called the navigon support yesterday, the woman who answered was helpless and terribly aggressive, I'm thinking about using TomTom now :)

Matthieu