If I want to unenrol all students from a Moodle 2.2.6 course (leaving all other users in place), I do the following:
- From the course, go to Participants link in the Navigation block
- Filter by role (setting it to student)
- Click the edit icon
- Select the students and press the 'remove' button
Unfortunately I have found that this removes the role but not the course enrolment - leaving me with many users in the course who have no role.
As far as I can tell, there is no other way to remove users by role, however I am more concerned about the fact that you can easily end up with many users in a course that have no role.
I suspect this is going to happen a lot by accident - is there any way of preventing this?
Many thanks for your help