ThinkGeo.com    |     Documentation    |     Premium Support

Using ReturningColumnsType.AllColumns

Hello,  I am using the code below the line to draw an ellipse  when the user clicks a point. It seems that using "ReturningColumnsType.AllColumns" is what is needed to draw the ellipse.  The ellipse has a radius of 10 miles.  All I am doing is adding the "selectedFeatures in the selectedFeaturesCollection to the new Collection efc and using  GetFeaturesIntersecting(selectedExtent) to find itself.  It seems that I should be able to do the following, but this doesn't show the ellipse.


Thanks, sckeels...



highlightEllipseLayer.InternalFeatures.Clear();

foreach(Feature selectedFeatures in selectedFeaturesCollection)

{

  highlightEllipseLayer.InternalFeatures.Add(selectedFeatures.Id, selectedFeatures);

}


_____________________________________________

highlightEllipseLayer.InternalFeatures.Clear();


foreach(Feature selectedFeatures in selectedFeaturesCollection)

{

 selectedExtent = selectedFeatures.GetBoundingBox();


  ellipseLayer.Open();

Collection<Feature> efc = ellipseLayer.QueryTools.GetFeaturesIntersecting(selectedExtent, ReturningColumnsType.AllColumns);

  ellipseLayer.Close();


  foreach(Feature ellipseFeature in efc)

  {

    string ellipseCellID = ellipseFeature.ColumnValues["CELLSITE_ID"];

    string selectionCellID = selectedFeatures.ColumnValues["CELLSITE_ID"];


    if(ellipseCellID == selectionCellID)

    {

      highlightEllipseLayer.InternalFeatures.Add(ellipseFeature.Id, ellipseFeature);

      break;

    }

  }

}



Hi Steven, 
  
 Could you check whether the count of the InternalFeatures at the end of the loop equals zero? If not, I guess that you missed refreshing the Overlay which contains the highlightEllipseLayer. If it doesn’t fix your issue, please send us a quick sample. 
  
 Any questions please let me know. 
  
 Thanks, 
 Howard