Andy McGovern - MSFT


You fed back, and we listened: presenting version 5.0 of the Virtual Earth API!

You might not have noticed, but over the past few months, we¡¯ve been busy poking around the Virtual Earth forums and blogs, listening to corporate customers and mashuppers alike, and coming up with a list of the top features and fixes that would make the best mapping API even better¡ªbetter for end users, but mainly better for you, the developer. We think you¡¯ll like what we¡¯ve come up with.

Welcome to version 5.0 of the Virtual Earth API. Of all of the requests we¡¯ve seen and heard, the one theme that kept coming back was more options for customization. So that¡¯s what we focused on. Are you tired of hacking your own customization into the mapcontrol We hear you. We thought ¡°hey, why don¡¯t we just support the ability to customize within the mapcontrol itself ¡± So we did. And we added some other cool stuff along the way. Read on to get the skinny. As you read about the new features, follow along by poking and prodding the Virtual Earth Interactive SDK, which is brand spankin¡¯ new for version 5.0. If you didn¡¯t think the Interactive SDK could get any better, you were wrong, because it has. Now, as you click around, you¡¯ll see that complex methods and code sequences are represented by interactive on-screen displays in the iSDK. So even if you aren¡¯t a developer, no worries: if you can fill out a web form and click a button, you can understand how the Virtual Earth API works.

Now, on to the features! For all you 3D developers out there, keep in mind that we work hard to maintain parity between 2D and 3D modes in the API. So most functionality below works in both 2D and 3D.

Pushpins, polylines, and polygons: Please allow me to introduce the VEShape class. Virtual Earth pushpins, polylines, and polygons have a lot in common, and now, they are members of the same class. Show and hide them; move them around by setting/changing their latlong points; throw custom HTML content at them to make custom icons (an image with a number or letter on top of it, for example); throw custom HTML and CSS at them to create custom info boxes that can be placed anywhere on the map (specify a pixel to dock it to the window OR a latlong to place it in the world); change polyline and polygon line width, fill color, transparency, etc. The list goes on and on.

Shape layers: With all this cool new shape functionality, it only makes sense to give you direct access to the shape objects, right That¡¯s what the VEShapeLayer class is for. As you add new shapes, throw them into a shape layer. Keep your favorite local bars (pushpins), your favorite bike trails (polylines), and favorite parks (polygons) separate and organized. Show one shape layer, and hide another. Iterate through a shape layer, access its shapes directly, and spruce them up (by giving them all a custom icon, for example). And now, GeoRSS imports (which now support polylines and polygons in addition to pushpins!), Live Search Maps Collections imports, and business searches using the Find method can now dump their shapes directly into a shape layer of your choosing.

Mouse and keyboard events: Would you like the ¡®b¡¯ key to mean ¡°Show my bike trails¡± instead of ¡°Switch to bird¡¯s eye view¡± Would you like the ¡°up¡± key to pan down, and the ¡°down¡± key to pan up (A bit strange, but whatever floats your boat.) Would you like a double click to create a new pushpin on that spot, instead of zooming in Would you like to highlight a polygon by changing its fill color when it is moused over To satisfy demand for all possible custom events, we decided just to hand you the keys. Now, capture any keyboard or mouse event imaginable: key presses, left/right/middle mouse clicks, mouseovers on shapes, and mouse wheel scrolls. If the mouse event happens directly on a VEShape object, you¡¯ll get direct access to that object to perform any action that you¡¯d like. Take the default Virtual Earth action along for the ride, or kill it and replace it with your own. It¡¯s up to you.

Those are the biggies, but here are a few one-liners, also new in version 5.0, that we thought you might like:

¡¤ In addition to pushpins, now you can import polylines and polygons using GeoRSS feeds.

¡¤ In the API, enjoy the same bird¡¯s eye panning experience from Live Search Maps that you know and love.

¡¤ Along with bird¡¯s eye panning comes programmatic control of the mini map: show it, hide it, and move it around.

¡¤ Speaking of bird¡¯s eye, you can now center a bird¡¯s eye scene on a latlong more accurately.

¡¤ Enjoy faster page load time with a compressed map control code base that is approximately 25% of its uncompressed size (from around 500kb to around 130kb).

¡¤ Speaking of performance, the initial map now loads faster because we stopped fetching an extra ring of invisible tiles around the map view. Want to turn it back on to improve initial panning No worries, we give you the choice.

¡¤ In addition to the default big kahuna dashboard, you now have your choice of two smaller navigation dashboards.

¡¤ We have revamped the Find method: you can now remove any or all of the Find method side effects, like the automatic map view change and the automatic display of pushpins.

¡¤ The tile layer API is now more straightforward and easier to use.

¡¤ We have added support for the Japanese market using programmatic market selection.

All of this great functionality comes at one small cost. If you¡¯d like to take advantage of the new features in your existing app, you¡¯re going to have to do a little work and upgrade it to version 5.0. Most of the new features are focused around the new VEShape functionality, and there was just no way to make it backward compatible with version 4.0. But it will be well worth it (we promise), and we will do everything possible not to make you go through this again for future versions.

Want to find out more As I mentioned above, the Virtual Earth Interactive SDK for version 5.0 is here. The complete MSDN reference SDK for Virtual Earth version 5.0 is here. And as always, the latest buzz, tips, and tricks about the Virtual Earth platform can be found here, in this MSDN VE Forum.

We hope you enjoy it! Make some cool apps showing off our new features, and let us know about them. Keith Kinnan, a Virtual Earth API developer, has already gotten a head start; you can check out his new version 5.0 sample apps here. And if you think we¡¯re taking a break now, we aren¡¯t. We¡¯re already hard at work on the next version!

Enjoy!





Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Earthware


What can I say, waht a release!

I can't wait to see what we all make of this, it answers so many of the hacks we have all been using and a few ones we hadn't even dreamed of.

Thanks guys a brilliant job!

Brian Norman
www.earthware.co.uk






Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

SoulSolutions

Great work Guys, can't wait to get stuck into it.

Anyone that comes across thing to update in the wiki feel free to update.

I'm in Thailand playing with elephants but will be back in two weeks and will run through everything then. Looks like a lot has been solved.

John.







Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Fred Chateau

Does anyone know if there is a CHM help file version available





Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

eddwo

You can now make your own fairly easily using PackageThis! http://www.codeplex.com/packagethis

You will also need the HTMLHelp Workshop package installed to compile the CHM. http://www.microsoft.com/downloads/details.aspx familyid=00535334-c8a6-452f-9aa0-d597d16580cc&displaylang=en

Worked well for me.





Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Lonifasiko

Andy McGovern - MSFT wrote:

All of this great functionality comes at one small cost. If you¡¯d like to take advantage of the new features in your existing app, you¡¯re going to have to do a little work and upgrade it to version 5.0. Most of the new features are focused around the new VEShape functionality, and there was just no way to make it backward compatible with version 4.0. But it will be well worth it (we promise), and we will do everything possible not to make you go through this again for future versions.

It's a pity it's not backward compatible. I've a couple of minutes ago tried my properly working application just changing v5 instead of v4, and the dissapoinment level has been incredibly great. I hoped more or less was going to work I now can't see any trace of my initial pushpins, my polygons, etc.

As you promise, would be nice for future releases if you would take into account the headaches programmers like me suffer when having to migrate from one version to another.

Thanks and regards.





Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Duncan Garratt

The main issue regarding version 5 for us developers is, will version 4 still be supported, and if so for how long! Backwards compatibility is essential for developers, and software houses, if the developer community are going to have confidence in recommending Microsoft products such as Virtual Earth.

Unless the naming conventions in JavaScript are the same, then there should be no reason why version 5 should not be backwards compatible! As a result of this change in the API, Microsoft have created a big headache for us developers, in that we need now upgrade our own software, and our clients.

In terms of building relationships between developers, and Microsoft, this is not professional, as what developers desperately need is stability when it comes to the Virtual Earth API. Being able to say to your customers that this software will run for X number of years is all-important when generating new business.

Having just spoken to the head of marketing in Europe for Microsoft Virtual Earth, who is running sales teams throughout Europe, I was most surprised to learn she was not aware of this problem, and could not give a definitive answer to this question.

Duncan Garratt

www.gis-logic.co.uk




Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

stanM

Hello,

The features are great!

I have a major complain though.

If I update my pushpins locations on a ShapeLayer ( I have a tracking app) I can see that it leaks memory ( a lot of memory) on each Shape position update

Also, if I do Zoom In/Out it leaks memory too!!

Are you aware of those major issues and if so, when the fix will come in

Regards,

Stan





Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Fred Chateau

PackageThis is so cool...

At first I hesitated because I didn't have time to fool around with Help Workshop. Then I finally decided to give it a try. I had my CHM file ready to use in less than ten minutes. Wow!

Thanks for the tip.

Regards,

Fred Chateau





Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Duncan Garratt

Important For Everyone¡¯s attention

I have been reliably informed that Microsoft plan to switch off version 4 on 31/12/2007. This for many developers will create a big headache, and possible contractual problems for developers who have written applications using the Virtual Earth version 4 API.

Ian Moulster from Microsoft has kindly taken this matter up with Virtual Earth management, and I hope to have an answer soon, which I will post.

Quote (Email received 12 May 2007)

¡°Hi Duncan, I¡¯ve been told that we¡¯ll keep v4 of Virtual Earth running to the end of this calendar year i.e. until 31/12/2007.

Rgds Ian.

Ian Moulster, Product Manager for .NET Platform, Developer & Platform Evangelism, Microsoft Ltd¡±

It is my view that Microsoft is placing Virtual Earth developers in a difficult position with their clients by switching off version 4 API. As a result of this news I have no alterative but to delay a major product launch planned for May 2007, whilst I upgrade my software to version 5.

Please note that developers who have sold annual Virtual Earth licences between Jan 2007 and April 2007, and who¡¯s software uses version 4 API could be in breach of contract with their clients, if this planned switch off goes ahead, unless they upgrade their software to use version 5 API.

In a competitive market place such as we have today, if developers are going to be messed around like this, then perhaps we should consider alternatives such as Google Maps, ESRI, and others!

There is a real problem here with communication as we developers, were not told about this. Microsoft if you want developers to support Virtual Earth, please keep the developer community updated at the earliest opportunity to planned changes, so we can plan accordingly!

Duncan Garratt

www.gis-logic.co.uk






Re: Version 5.0 of the Virtual Earth API has been released! Important For Everyone¡¯s attention

Lonifasiko

After worryingly reading Duncan's post, I expect Microsoft not to abandon MapControl v4 after 2007, cause this will give me very much headaches. Although newer version has been published, I think they should continue providing access to older versions like v4.

For you MS, it's as simple as mantaining active a URL with the MapControl v4 javascript library. We, developers of MapControl v4, would really appreciate that.

Hope these poor words are taken into account.

Regards.