Working with attributes of a Graphic
Hi to all
time for what would seem a silly question, so here is where I am up to:
- I have a FeatureSet from a selection earlier in a workflow.
- I am able to iterate through the Graphics in the Featureset popping up an Alert to report the number of attributes of each Graphic. This is done using ParallelForEach<Graphic>
I am now attepting to iterate through the Attributes of each Graphic. Suposedly the attributes are accesed via an IDictionary(Of String, Object) ie field name and value.
I have tried to set a variable with the type of IDictionary<String,Object> (with or without a default) but cannot seem to be able to Assign it the value of Graphic.Attributes.
Also tried was a ForEach<KeyValuePair<String,Object>> and ParallelForEach<KeyValuePair<String,Object>> to loop through the Atrributes but still no joy.
Has anyone managed to achieve this sort of task?
Thanks
Ralph Price
-
ForEach string key in Graphic.Attributes.Keys should work. Then you can grab the actual values like this: myObject = Graphic.Attributes(key)
0
Please sign in to leave a comment.
Comments
1 comment