PROBLEM
When using an ArcMap Image Service in the HTML Viewer in ArcIMS 9.2 that includes group layers, annotation layers, or a combination of the two, there are problems turning layers on and off in the TOC.
Note:
This is not an issue when using earlier versions of ArcIMS.
At ArcIMS 9.2, two new attributes were added to LAYERINFO in the SERVICEINFO response for ArcMap Image Services: arcmaptype and parentlayerid. The attribute descriptions are:
· arcmaptype: Returned for ArcMap Image Services when a layer is a group layer, annotation layer, or multipatch layer.
· parentlayerid: Returned for ArcMap Image Services for each layer that belongs to a group in LAYERINFO. This includes annotation layers. Group layers can be nested.
The purpose of these attributes is to allow custom applications to differentiate between regular data layers and annotation, group, and multipatch layers.
When the HTML Viewer is parsing the SERVICEINFO response, it looks for the layer 'id'. In the case where 'parentlayerid' is included in the response, the attribute value for 'parentlayerid' is used instead of 'id'. This leads to the incorrect behavior in the TOC.
Code:
startpos = theReplyUC.indexOf("ID=",lpos);
if ((startpos != -1) && (startpos<zpos)) {
startpos = startpos + 4;
Code:
startpos = theReplyUC.indexOf(" ID=",lpos);
if ((startpos != -1) && (startpos<zpos)) {
startpos = startpos + 5;
Note:
The code changes include a space before "ID=" to " ID=" and startpos incremented from 4 to 5
Article ID:000009276
Get help from ArcGIS experts
Download the Esri Support App