Editor problem- can't select multiple features and the selected feature not highlighted

2723
0
03-02-2015 10:33 AM
YingLin
New Contributor

i have a silverlight API app. have setup the Editor for selection.in xaml, i have the following setup

<esri:Editor x:Name="lotsEditor" ContinuousMode="True" LayerIDs="lots"  EditCompleted="lotsEditor_completed" SelectionMode="Rectangle" Map="{Binding ElementName=Map}">

<esri:FeatureLayer ID="lots" Mode="SelectionOnly" OutFields="*" SelectionColor="Red" Url="http://chgis/internal/rest/services/Live/property/MapServer/14" Initialized="lots_initialized"></esri:FeatureLayer>

 

in code behind, i have the following

  private void lots_initialized(object sender, EventArgs e)

        {

            editor = LayoutRoot.Resources["lotsEditor"] as Editor;

            if (editor.Select.CanExecute("Add"))

            {

                editor.Select.Execute("Add");

            }

        }

 

private void lotsEditor_completed(object sender, Editor.EditEventArgs e)

        {

            if (e.Action == Editor.EditAction.Select)

            {

               

                    foreach (var item in e.Edits)

                    {

 

                      } 

           }

}

 

when I hold the CTRL button, only one feature is selected and the selected feature is not hightlighted in RED like setup in xaml.

Couldn't figure out what is the problem. any keen eye can help me out? I have looked at my script many times and couldn't figure out what the problem is. Thanks very much.

0 Kudos
0 Replies