Select to view content in your preferred language

Setting feature retrieveal from feature server programatically

478
1
11-19-2013 12:07 AM
JohanCarlsson
Regular Contributor
Hi!

I've made an application in the Silverlight Viewer. I made tool myself for adding items from the portal, there are also two tools from ESRI called AddContentCommand and another AddIn called SearchTool.

When I add FeatureLayers from these different sources, they all behave differently and I can't find the controlling parameter for this. What I want is, regardless of the source, that features should only be retrieved within the maps extent. Right now it seems to be just random, or based in the settings of the previously loaded layer.

This picture shows the setting in the viewer, but I'd like to do it programatically with a behavior, i.e. any FeatureLayer added should have this setting by default.
[ATTACH=CONFIG]29194[/ATTACH]

Any help regarding this would be greatly appreciated.

Regards
Johan
0 Kudos
1 Reply
DominiqueBroux
Esri Frequent Contributor
Hi!

I've made an application in the Silverlight Viewer. I made tool myself for adding items from the portal, there are also two tools from ESRI called AddContentCommand and another AddIn called SearchTool.

When I add FeatureLayers from these different sources, they all behave differently and I can't find the controlling parameter for this. What I want is, regardless of the source, that features should only be retrieved within the maps extent. Right now it seems to be just random, or based in the settings of the previously loaded layer.

This picture shows the setting in the viewer, but I'd like to do it programatically with a behavior, i.e. any FeatureLayer added should have this setting by default.
[ATTACH=CONFIG]29194[/ATTACH]

Any help regarding this would be greatly appreciated.

Regards
Johan

That's controlled by the FeatureLayer Mode property: Snapshot or OnDemand.
0 Kudos