Display a map in a Windows Form app
Solution 1
Both Google Maps and Live Maps have a public api.
Since you are doing winforms I'd probably use live maps.
http://dev.live.com/VirtualEarth/
There are a few examples on CodePlex.
http://codeplex.com/Project/ProjectDirectory.aspx?TagName=Virtual%20Earth
Solution 2
There is some example code for developing a map viewer control (NB: I doubt this is strictly within their licence)
Otherwise, depending on your budget, you could use the MapPoint ActiveX control
Solution 3
Just use the value inside the src="" as the location for a WebBrowser control directly, without the IFRAME.
OR
Build a minimal html document wrapping the IFRAME, write it out to a MemoryStream, re-seek it back to the start, and use the MemoryStream to set the WebBrowser control's DocumentStream property.
PW
user6793644
Updated on June 15, 2022Comments
-
user6793644 almost 2 years
I have to make a button that everytime it is clicked it adds one to the counter. SO counter would look like this. Counter: 0 and then once the button is clicked counter goes to one and so on. So far it only goes up to the number one.
my js code is:
var $ = function (id) { return document.getElementById(id); }; var counter; function start(){ var button = document.getElementById("button"); window.addEventListener("click", count, false); }; function count(){ counter = document.getElementById("counter"); counter = counter+1; document.getElementById("count").innerHTML = counter; }; window.addEventListener("load", start, false);
my html code is:
<html> <head> <title>12.5 valenti</title> <meta charset = "uft-8"> <script type="text/javascript" src="12.5.js"></script> </head> <body> <div> <p><input type = "button" id="button" value = "button"></p> <p> count: <span id = "count">0</span></p> </div> </body> </html>
-
A. L about 7 yearsyou can't +1 an element like that
-