string search = textBoxNachname.Text;
var Liste = _db.T_Subscribers
.Where(x => x.firstname.StartsWith(search))
.Except(_selectedcourse.T_Coursedetail.Select(b => b.T_Subscribers))
.Where(M => M.T_Tln_Student == null || M.T_Tln_Stud.Status.T_Status.T_Statusart == _studentEx).ToList();
I have written the above piece of code to extract a list whose name starts with the Search element in textbox...then I need to exclude the names who have already enrolled for the course, then if they are not the students of the Institution (M => M.T_Tln_Student == null)
and ex-students include in the list..
But I am getting Null reference exception occurred...