Creating a Flared Cluster on a Graphics Layer

3928
7
Jump to solution
07-09-2012 01:40 PM
AnthonyGiles
Frequent Contributor
All,

I have developed a widget for Flex Viewer 2.5 that sends a SOAP request to a web service of a 3rd party application.

The response to the SOAP request contains various fields for a number of records, two of which are the latitude and longitude of the record. I create a graphics layer then I parse through the results to plot the locations as individual graphics (picture marker symbols using an icon from a URL in each record) adding them to the graphics layer. Each graphic can then be clicked on to view its attributes in a pop up.

This all works fine, the trouble I am having is that if more than one record is in the same location I can only click on the uppermost graphic to view the attributes. Is there anyway I can create a flared cluster (keeping the original icon and ability to click to see attributes when flared) on loactions than have more than record?

Any help or advice would be appreciated

Regards

Anthony
0 Kudos
1 Solution

Accepted Solutions
AnthonyGiles
Frequent Contributor
All,

I found the solution by using a clusterer on the graphics layer with a flare. If anyone else is interested in the solution let me know.

Regards

Anthony

View solution in original post

0 Kudos
7 Replies
AnthonyGiles
Frequent Contributor
All,

I found the solution by using a clusterer on the graphics layer with a flare. If anyone else is interested in the solution let me know.

Regards

Anthony
0 Kudos
ShwetaMorkhandikar
New Contributor
I am surely interested in this solution. I tried using clusters in 2.5 but the numbers get scrambled. I hope this widget should solve my problem
0 Kudos
AnthonyGiles
Frequent Contributor
Shweta,

I have not developed a widget purely for clustering data as this is already a native function on feature layers. What I have done is added the cluster ability to graphic layers used in other widgets that I have developed to work against other applications on our closed network.

Attached is the source code for an add excel file widget that utilises the clustering capability. This is source code so that you can see how the cluster is added to a graphics layer, this is meant for developers and not as a compilied widget.

Regards

Anthony
0 Kudos
ShwetaMorkhandikar
New Contributor
Thank You Anthony
0 Kudos
PawanVuppala
Occasional Contributor
Hi Anthony,
I dont see an attachment to the post.  Please let me know if there is a link anywhere.
Shweta,

I have not developed a widget purely for clustering data as this is already a native function on feature layers. What I have done is added the cluster ability to graphic layers used in other widgets that I have developed to work against other applications on our closed network.

Attached is the source code for an add excel file widget that utilises the clustering capability. This is source code so that you can see how the cluster is added to a graphics layer, this is meant for developers and not as a compilied widget.

Regards

Anthony
0 Kudos
AnthonyGiles
Frequent Contributor
Pawan

I have seemed to have deleted all attachments I have uploaded somehow,

You can find the code in this widget:

http://www.arcgis.com/home/item.html?id=b8d2f6a9063e44669eddfdd2d32244e8

Regards

Anthony
0 Kudos
veenahosur1
New Contributor II

please can you provide your resulted data

0 Kudos