I have an IEnumerable of Lesson objects:
IEnumerable<Lesson> filteredLessons
I convert it to a List through the following method:
ToList();
But I want the returned list to contain only the first property, lessonid, not all the Lesson properties.
How can I get the data of specific property of the list instead of the objects?
You can select the value you want first, like this:
And you’ll get a list of ID’s