laptop and a wrench

Bug

Edits to layerdefinitions are not being saved consistently for MapResourceItem.

Last Published: August 25, 2014 ArcGIS Server (.NET)
Bug ID Number NIM039011
SubmittedOctober 2, 2008
Last ModifiedJune 5, 2024
Applies toArcGIS Server (.NET)
Version found9.3
StatusWill Not Be Addressed

Additional Information

No Public Explanation

Workaround

Copy and paste the following code snippet in the Page_Load part. Remove everything in the LayerDefinitions column in the MapReourceManager control.=========================================== if (!MapResourceManager1.Initialized) MapResourceManager1.Initialize(); LayerDefinitionCollection layDesCol = (LayerDefinitionCollection)MapResourceManager1.ResourceItems[0].LayerDefinitions; for (int i = 0; i < layDesCol.Nodes.Count; i++) { if (layDesCol.Nodes[i].Text == "States") // here "States" is the layer name, replace with your layer name which you want to customize { LayerDefinition layDef = (LayerDefinition)layDesCol.Nodes[i].Data; layDef.LayerFormat.Fields[3].Visible = false; layDef.LayerFormat.Fields[4].Visible = false; layDef.LayerFormat.Fields[5].Visible = false; MapResourceManager1.ResourceItems[0].UpdateLayerDefinitions(); } }===========================================

Steps to Reproduce

Bug ID: NIM039011

Software:

  • ArcGIS Server (.NET)

Get notified when the status of a bug changes

Download the Esri Support App

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options