public static List<CodificacionInstalacion> Instalacion(string searchText, int maxResults) { Repositorio repo = new Repositorio(); List<CodificacionInstalacion> names = new List<CodificacionInstalacion>(); DataSet sitiosDset = repo.GetInstalaciones(); foreach (DataRow row in sitiosDset.Tables[0].Rows) names.Add(new CodificacionInstalacion { id = row.ItemArray[2].ToString(), code = row.ItemArray[0].ToString(), desc = row.ItemArray[1].ToString() }); var result = from n in names where RemoveDiacritics(n.desc).ToUpper().Contains(searchText.ToUpper()) orderby n.desc select n; return result.Take(maxResults).ToList(); }