Original User: mmestrov
Something like this.....
private void MyMap_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
{
FeatureLayer fl1 = MyMap.Layers["RedlineParkingStalls"] as FeatureLayer;
FeatureLayer fl2 = MyMap.Layers["RedlineParkingLots"] as FeatureLayer;
FeatureLayer fl3 = MyMap.Layers["ParkingStalls"] as FeatureLayer;
FeatureLayer fl4 = MyMap.Layers["ParkingLots"] as FeatureLayer;
Point Pt = e.GetPosition(MyMap);
MapPoint newMapPt = MyMap.ScreenToMap(Pt);
System.Windows.Point screenPnt = MyMap.MapToScreen(newMapPt);
GeneralTransform generalTransform = MyMap.TransformToVisual(Application.Current.RootVisual);
System.Windows.Point transformScreenPnt = generalTransform.Transform(screenPnt);
FeatureLayer[] fllist = new FeatureLayer[] { fl1, fl2, fl3, fl4 };
foreach (FeatureLayer fl in fllist)
{
IEnumerable<Graphic> selected = fl.FindGraphicsInHostCoordinates(transformScreenPnt);
foreach (Graphic g in selected)
{
MyFeatureDataForm.GraphicSource = g;
}
}
}
The problem is my FeatureDataForm is not displaying anything. My ultimate goal is to take all the graphic select from all the featurelayers that the point intersects and be able to page through the FeatureDataForm to the one I want to update. Hope I'm making sense.