<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ListBox multiple items selection in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430742#M11138</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use the &lt;A href="https://msdn.microsoft.com/en-us/library/system.windows.controls.listbox.selecteditems(v=vs.110).aspx"&gt;SelectedItems&lt;/A&gt; property which returns the list of selected items.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 13 May 2015 13:36:48 GMT</pubDate>
    <dc:creator>DominiqueBroux</dc:creator>
    <dc:date>2015-05-13T13:36:48Z</dc:date>
    <item>
      <title>ListBox multiple items selection</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430739#M11135</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have two-step query: query 1 selects all routes for given school and displays route numbers in a ListBox. Query 2 allows for selecting&lt;BR /&gt;one of routes from a ListBox. I am wondering how to select more than one route from a ListBox.&lt;/P&gt;&lt;P&gt;So here is my ListBox:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="background: white; color: #a31515; font-family: Consolas; font-size: 9.5pt;"&gt;StackPanel&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; Orientation&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="Horizontal"&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;BR /&gt;HorizontalAlignment&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="Left" &amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="background: white; color: #a31515; font-family: Consolas; font-size: 9.5pt;"&gt;TextBlock&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; Text&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="Routes:"&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; Width&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="100"&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; TextAlignment&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="Left"&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; Margin&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="5,5,-2,5"/&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="background: white; color: #a31515; font-family: Consolas; font-size: 9.5pt;"&gt;ListBox&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; x&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="RoutesFound"&lt;/SPAN&gt; &lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; Width&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="50"&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; Margin&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="5"&lt;/SPAN&gt;&lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; SelectionChanged&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="selectedRoute_SelectionChanged"&lt;/SPAN&gt; &lt;SPAN style="background: white; color: red; font-family: Consolas; font-size: 9.5pt;"&gt; SelectionMode&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;="Extended" /&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="background: white; color: #a31515; font-family: Consolas; font-size: 9.5pt;"&gt;StackPanel&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/SPAN&gt; &lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;void&lt;/SPAN&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt; selectedRoute_SelectionChanged(&lt;/SPAN&gt;&lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;object&lt;/SPAN&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt; sender, &lt;/SPAN&gt;&lt;SPAN style="background: white; color: #2b91af; font-family: Consolas; font-size: 9.5pt;"&gt;EventArgs&lt;/SPAN&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt; e)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt; (RoutesFound.SelectedIndex != -1)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _strSelectedRoute = RoutesFound.SelectedValue.ToString();&lt;/SPAN&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0px 0px 0px 0.5in;"&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _listSelectedRoutes.Add(_strSelectedRoute);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background: white; color: black; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;where I added SelectionMode ="Extended" with a hope that it will allow me for multiple selection, but this did not happen.&lt;/P&gt;&lt;P&gt;I also tried to use SelectionMode ="Multiple", but without luck.&lt;/P&gt;&lt;P&gt;Does anybody can suggest how to select multiple items from aListBox and capture them in a list?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 May 2015 19:50:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430739#M11135</guid>
      <dc:creator>JoannaLaroussi</dc:creator>
      <dc:date>2015-05-08T19:50:37Z</dc:date>
    </item>
    <item>
      <title>Re: ListBox multiple items selection</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430740#M11136</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;in xml &lt;/P&gt;&lt;P&gt;&amp;lt;listbox1.item "schools/&amp;gt;&lt;/P&gt;&lt;P&gt;code behind &lt;/P&gt;&lt;P&gt;ListBox listBox1 = &lt;SPAN style="color: blue;"&gt;new&lt;/SPAN&gt; ListBox();&lt;/P&gt;&lt;P&gt;listBox1.Items.Add(&lt;SPAN style="color: #a31515;"&gt;"schools"&lt;/SPAN&gt;);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 May 2015 23:28:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430740#M11136</guid>
      <dc:creator>Asgharkhan</dc:creator>
      <dc:date>2015-05-08T23:28:03Z</dc:date>
    </item>
    <item>
      <title>Re: ListBox multiple items selection</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430741#M11137</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for your response, but I do not see it how this can help me.&lt;/P&gt;&lt;P&gt;I would like to capture selected items from XAML, and I do not need to add more items in C#.&lt;/P&gt;&lt;P&gt;Right now this line&lt;/P&gt;&lt;P&gt;_strSelectedRoute = RoutesFound.SelectedValue.ToString();&lt;/P&gt;&lt;P&gt;captures a single selection, but I need to be able to capture multiple selection.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 May 2015 19:05:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430741#M11137</guid>
      <dc:creator>JoannaLaroussi</dc:creator>
      <dc:date>2015-05-12T19:05:46Z</dc:date>
    </item>
    <item>
      <title>Re: ListBox multiple items selection</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430742#M11138</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use the &lt;A href="https://msdn.microsoft.com/en-us/library/system.windows.controls.listbox.selecteditems(v=vs.110).aspx"&gt;SelectedItems&lt;/A&gt; property which returns the list of selected items.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 May 2015 13:36:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/listbox-multiple-items-selection/m-p/430742#M11138</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2015-05-13T13:36:48Z</dc:date>
    </item>
  </channel>
</rss>

