Hi, I have developed a identify tool where I am reading my LayerKeyField from the IdentifyResults int intFeatureCount = 0;
//store LayerName and ID
foreach (IdentifyResult result in results)
{
if (!dicIdentifyResults.Keys.Contains(Convert.ToInt32(results[intFeatureCount].Feature.Attributes["ROADID"])))
{
//store identify results with the layername
dicIdentifyResults.Add(Convert.ToInt32(results[intFeatureCount].Feature.Attributes["ROADID"]), results[intFeatureCount].LayerName);
intFeatureCount++;
}
}
the above code works fine... butWhen I query the using QueryTask and read my attribute from that result I dont get the value FeatureSet pFeatureSet = e.FeatureSet;
if (pFeatureSet == null) return;
if (pFeatureSet.Count() < 1) return;
int intID = Convert.ToInt32(pFeatureSet.Features[0].Attributes["ROADID"])
//but
int intID = Convert.ToInt32(pFeatureSet.Features[0].Attributes["roadid"])
;
but when I use lower case keyfieldname it works fine .. how is it that it works fine for IdentifyTask but QueryTaskI have also changed the alias name of field to Uppper case in using ArcMapam i missing something here