I get this error message:
The type arguments for method \'System.Linq.Enumerable.Select(System.Collections.Generic.IE
Select is not a replacement for a foreach. Use this instead:
ObservableCollection documentsOC = new ObservableCollection();
IEnumerable documents = _docRepo.GetDocumentsByPupilId(_selectedPupil.Id);
foreach(var doc in documents)
{
documentsOC.Add(doc);
}
SelectedPupil.Documents.DocumentList = documentsOC;