Julie98


Hi,

When the map is at a lower zoom level, some shapes are on top of each other, if you hover over, only the top shape will provide the info box, the rest of the shapes are just buried, unreachable, unless you zoom in more to see individual shapes.

I do not want to confuse the user into thinking there is only one shape in the location he points at. I would like to provide all of the shapes' information when the top shape is pointed to.

Is there a way to calculate the boundary of the shape and figure out which of the shapes fall into that boundary so that I can combine the information and show it in one info box I know I can probably do some latlong to pixel type of caculation but not quite sure if VE has all the APIs I need...

Any pointers will be very appreciated!

Sincerely yours,

Julie98




Re: How to detect the all the shapes that are in the same boundary?

SoulSolutions


Yes it is possible to detect an overlapping pin. In version 5 it is a lot easier.

I have completed two methods, firstly a server side solution that effectively clusters the overlapping pins:

http://www.viavirtualearth.com/vve/Articles/Clustering3.ashx

The second solution was for a client who wanted the pin-on-a-stick functionlaity as per MapPoint, purely in javascript we detected overlaps, changed the pins to polylines and repositioned so no overlaps occurred.

Unfortunatly detecting the exact boundary of not trival as pins can now be icons and also html.

John.







Re: How to detect the all the shapes that are in the same boundary?

Julie98

John,

Thanks for your help!