Just for the record... a solution to the same problem on a different site was... In Users/Permissions/Define Roles (Student - Edit)... I changed "moodle/course:view" to Allow. For some reason this was turned off which meant that (after being correctly enrolled) any time a student went into the course they were sent back into enrolment!.
Alan.
(I did not solve Karl's problem because he did follow up with me.)