Proof of concept mapviewer for the Desktop - thoughts?

Hello Everyone,

I am exploring a proof-of-concept application for the desktop which uses a map (Google maps?). If much of the work has been performed by Google, There is no need to recreate an existing tool. This application will be populated with many locations and the user is able to draw on the map (radius from a point), have grids, land site descriptions for North America, and show information when rolling over the location after resizing the map. The immediate need is that this application will be limited to desktop only.

Can all of this be performed with Google maps? Another option is to have Google maps on a bottom layer with markups and drawing with a canvas that is on top of the map. Multiple layers would then need to be synchronized when zooming in.

An initial thought is to use JSON for javascript calls to Google maps, or use as much of the API’s with http calls.

Am I on the right track? I am asking for some general thoughts. Thanks for your help. :slight_smile:

Sure. Google Maps will render an image for you, which you can draw in a Canvas. Be sure to carefully review their Terms of Service. You can’t charge for the maps feature, and request rate limits apply. A recent app I wrote, it took me a week of background time to research and get my head around the parameters and maybe half a day to implement map display with reverse geo-location.

Thanks for your help Brad, and I will look into the Terms of Service - chuckle, I will put my legal hat on and make sure to know where the boundaries are. :slight_smile: I’ll dig into getting a picture which is documented in the Framework User Guide.

Thanks a bunch!

I used this code from the Xojo forums and am getting an error 302.

[code] Dim socket As New HTTPSocket
Dim data As String = socket.Get(“http://maps.google.com/maps?q=loc:51.045+-114.057222&z=10&output=embed”, 5) ’ using synchronous GET

If socket.HTTPStatusCode = 200 Then ’ OK
’ Picture.FromData creates a new picture from raw binary data
Dim p As Picture = Picture.FromData(data)

If p <> Nil Then
  ImageWell1.Image = p
Else
  MsgBox("Not a picture.")
End If

Else ’ errors, redirects, etc.
MsgBox("HTTP Status: " + Str(socket.HTTPStatusCode))

End If[/code]

My guess is the socket has the connection, but doesn’t understand the redirect to the latitude and longitude and gives the 302 error. I am sure that I am missing something simple, and does anyone have a helpful suggestion?

Got it…

Needed to add :

socket.Yield = True :slight_smile:

Depending on what you are trying to do you may want to look into http://www.openstreetmap.org as well. I’ve had some success with it in the past.

Thanks for the suggestion Bob!

I didn’t even know that this existed. After doing a few searches and trying some code, it looks like it will do almost everything that is needed.

Greatly appreciated.

Hi there Eugene Dakin did you mange to get this working , I’m quite interested I’ve gave it bash by in getting an error 302.
Has anybody tired the Good api , i keep getting can’t do this without an iframe

Cheers Clev

Thanks to the helpful information from Tim Hare, the following link is a working example of Google Map. :slight_smile:

Google Map Example

Happy to help

please review this carefully. I was going to use their mapping service in one of my apps then I read that ToS and scrapped the app.

http://www.microsoft.com/maps/Licensing/licensing.aspx
https://developers.arcgis.com/en/
http://developer.mapquest.com/web/tools/getting-started/terms-overview
http://developer.tomtom.com/products/map_toolkit_api

[quote=132679:@shao sean]http://www.microsoft.com/maps/Licensing/licensing.aspx
https://developers.arcgis.com/en/
http://developer.mapquest.com/web/tools/getting-started/terms-overview
http://developer.tomtom.com/products/map_toolkit_api[/quote]
http://developer.here.com/terms-conditions-eval

What part of the TOS could you not agree with?

Well this was a few years back. In the ToS of Google and Yahoo maps (I think it was Yahoo, it might have been Microsoft/bing) said that if the app was paid for, you had to pay a monthly fee for using their API. The only way to use the API for completely free, you had to make sure that the app was completely free (including no in-app upgrades).

Now I know that they have changed the ToS since then at least once. I dont know if those limiters are still in there or not.

I know the Navteq, err I mean Nokia, err I mean HERE’s APIs & ToS seem to be a little more lenient to their use.

readers digest version: I didnt want to pay for API access, and since the app would be sold, I couldnt use their APIs.

thanks
sb

note: Navteq got bought by Nokia and then spun into a division called HERE - all of which was done in the last few years.

if you would like more information on this, please feel free to reach out to me directly. this goes for any of you…

see http://developer.here.com/get-started for using HERE’s APIs.

Why is Nobody Talking about Apple maps?

Nobody is talking about Apple Maps

hi Guys wow nice on the responses, Eugene i found the google java map in the examples with xojo thanks for that , i think I’m on a bit of a role after reading some of the google java docs ,
i then found that you can encode base64 the image in the image well control much like MHML or saving to sql in php just remember to convert the encoding to utf8 before putting it in the html , post that in to the java much like the address works on the sample . and woot got my own image in the html viewer java google map thing. code below to base 64 for use in html

Dim s As String = MyPic.GetData(Picture.FormatPNG,0)
s = "data:image/png;base64, " + ConvertEncoding( EncodeBase64(s,0), Encodings.utf8 )

on the EncodeBase64(s,0) the 0 get rid of all the line returns required for html
in the Java use the replace function like the address in the sample with the " around it
var image = “%MYIMAGE%”;

to be honest i was quite impressed with my self
next thing to do is take the weather from the free online weather Api and overlay on the map on that note the next hurdle will be how to rotate the image, i do wounded if it would be better to do it then java script than the image well ?
never thought about apple maps does this have an API ??
and what the concedes on the google map API will it cost if you ever went fully commercial is it ok for business projects that runs on only one device ?