Exemplo n.º 1
0
 private static void DeepRemoveFilter(FilterElementCollection filterColl, FilterElement toRemoveFilter)
 {
     if (filterColl.Contains(toRemoveFilter))
     {
         filterColl.Remove(toRemoveFilter);
     }
     foreach (FilterElement filterEl in filterColl)
     {
         if (filterEl.HasChildElements)
         {
             DeepRemoveFilter(filterEl.ChildElements, toRemoveFilter);
         }
     }
 }
Exemplo n.º 2
0
 private static void DeepRemoveFilter(FilterElementCollection filterColl, FilterElement toRemoveFilter)
 {
     if (filterColl.Contains(toRemoveFilter))
     {
         filterColl.Remove(toRemoveFilter);
     }
     foreach (FilterElement filterEl in filterColl)
     {
         if (filterEl.HasChildElements)
         {
             DeepRemoveFilter(filterEl.ChildElements, toRemoveFilter);
         }
     }
 }