I am new to Moodle and might be doing something silly, but for the life of me I cannot get the automatic enrollment with an external database right. Let me add here that i am trying to external user registration AND enrollment in one step.
I have therefore set up an external database with username, password, idnumber (which for testing purposes i've just created as a semi random string) and course ID (which corresponds to a string identification that I've put in on the course side in the course idnumber field). The Username and Password link works fine, the user account is created (with the semi-random string in the user idnumber field), but he is not added to the course. If I take off internal enrollments as an option on the enrollment parameters for using an external database, when the user clicks on the course it just comes back with an error - sorry, internal enrollments are not allowed, even though the user has been authenticated, logged in and saved his parameters.