title: Can I use linq to remove items from asp .net DropDownList.Items?
body: <p>As title says, is it possible to use LINQ to remove Items from a DropDownList's .Items where the Item is not equal to strings that I specify?</p>
  
  <p>To put it another way - I have a list of strings, if an Item doesn't match any string in the list, it is removed.</p>
  
  <p>NOTE: I know how to achieve this, I can do it with a foreach loop. That's fine - but I want to know if there's a LINQ alternative.</p>
  
  <p>EDIT: I should say - the Item's <strong>.Text</strong> property matches any item in the list of strings.</p>
  
  <p>EDIT: For those interested, this was my proposed 'foreach' way:</p>
  
  <pre><code>        private void FilterDropDownChoices(List&lt;String&gt; permittedChoices)
          {
              foreach(ListItem item in ddlChoices.Items)
              {
                  if (!permittedChoices.Contains(item.Text))
                  {
                      ddlChoices.Items.Remove(item);
                  }
              }
          }
  </code></pre>