Select to view content in your preferred language

Access to Graphics collection on FeatureLayer

1201
3
04-24-2011 11:28 PM
juliangarcia-anton
Emerging Contributor
Hi,

In a project using ESRI Silverlight api version 1.2, I was able to add a FeatureLayer to my map, (the layer resides in ArcGIS Server 9.3.1) and could access the Graphics Collection to interact with the features on the layer.

I have updated the project to use the ESRI Silverlight api version 2.1, in order to use some new funtionality, but now I find that the Graphis Collection is empty and I cannot find a way to access the features on the layer.

Is this a new limitation imposed by the new api, or is there a different way to access features on a FeatureLayer ? Would upgrading to ArcGIS Server 10 solver the issue ?

Thanks.
0 Kudos
3 Replies
DominiqueBroux
Esri Frequent Contributor
I don't see any limitation imposed by the new API which could explain your issue.

Check that your service is avilable and that you can get the features using the REST API (something like http://serverapps.esri.com/ArcGIS/rest/services/California/MapServer/0/query?text=&geometry=&geometr...).

Then if you service is working, you will need fiddler to figure out the issue.
0 Kudos
juliangarcia-anton
Emerging Contributor
Thanks for your reply Dominique,

I did finally solve the issue, by accessing the features at the UpdateCompleted event, instead, of the Initialized event for the FeatureLayer.  So I do think that there is a slight difference because with the 1.2 DLL the graphics collection at the Initialized event was full, and in version 2, it is empty.

Thanks again.
j.
0 Kudos
dotMorten_esri
Esri Notable Contributor
I can confirm that this is a slight change of behavior between 1.x and 2.x.
0 Kudos