Flash Google Map

Google Map, an useful tool in our daily life. Lots of us has already known how to use javascript version google map. Today, we will talk about how to use flash version and how to fulfill run-time searching.

The source file will be provided at the end of the poster (page2). If you are interested, can click to download it.

We can find lots of examples of predefined flash google map application. Which means “predefined”? It means you have to set the coordinates within the flash authorizing tool; and as long as it is defined, you won’t the able to change the coordinates again unless you republish the .fla file with updated coordinates.

Here is the example of “predefined” maps;

In above example, we have to predefined coordinates of A-F six points in flash authorizing tool.

For instance, to define point A, we have to use code like following:

myLayer.addPoint({lat:37.784147,lng:-122.417736, index:“A”,name:”San Francisco”,fillRGB:0xFFFF00,strokeThickness:1});

How to can realize real-time searching, just like you are using maps.google.com?
Below is a simple example I made, which allow you to input your address, then the flash will show the place area you try to find in the middle of the map;

Try to put postcode or you detail address in the textfield, press “find” button, just like you are using google map. The map will change to the area you are looking for.

In next page, we will talk about how to fulfill that;

Share this post:

5 Comments

Leave a Comment.