A dispensing system for medication comprising a dispenser into which the canister of medication is placed. The dispenser has a locking mechanism for selectively preventing dispensing of the medication. The system receives input data from a user and has a control device remote from the dispenser to lock the dispenser until the input data is correctly entered.