Hi,
On later versions of Moodle (2.7 onwards, I belive) you can use Event Monitoring as mentioned above. If this is enabled, it allows you to create event triggers for specific courses. Once enabled, go to your desired course and within the course administration panel select "reports". Then from the drop down list select "Event monitoring rules". If you "Add a new rule" you will be prompted with a form to create a new event. For the area to monitor field you want to choose "Core" and then "Course completed". This then sends an email to (I believe) the teacher of the course. It sent me the following email:
Rule name: Course Completed
Description:
Test Course Completed
Event name: Course completed
I stopped testing it after this as it didn't actually tell me who had completed the course. It's something I really need to look at though and get working.
PS: I've read that it slows your website down tremendously, so I'd do testing.