Exemplo n.º 1
0
        void FilterItems(string filter)
        {
            var filteredItems = source.Where(Patient => Patient.Evaluation.ToLower().Contains(filter.ToLower())).ToList();

            foreach (var Patient in source)
            {
                if (!filteredItems.Contains(Patient))
                {
                    Evaluations.Remove(Patient);
                }
                else
                {
                    if (!Evaluations.Contains(Patient))
                    {
                        Evaluations.Add(Patient);
                    }
                }
            }
        }