I'm trying to move points that are stacked on top of one another in an InMemoryFeatureLayer. The problem is when I update the points with the new coordinates it doesn't persist and they still show up on top of each other on the map. In my Update call I'm using the Id of the feature that I want to update. Am I missing something? Thanks in advance.
Chad
foreach (Feature feat in layer.InternalFeatures)
{
Collection<Feature> feats = layer.QueryTools.GetFeaturesIntersecting(feat.GetShape(), ReturningColumnsType.NoColumns);
if (feats.Count > 1)
{
double angleInterval = (double)360 / (double)feats.Count;
double curAngle = 0;
layer.EditTools.BeginTransaction();
foreach (Feature moveFeat in feats)
{
PointShape ps = (PointShape)moveFeat.GetShape();
ps.TranslateByDegree(20000, curAngle, GeographyUnit.DecimalDegree, DistanceUnit.Feet);
layer.EditTools.Update(new Feature(ps.X, ps.Y, moveFeat.Id));
curAngle = curAngle + angleInterval;
}
layer.EditTools.CommitTransaction();
}
}