In general, the easiest way to train an animal is by positive reinforcement. The basic principle is to "shape" the behavior that is desired by offering a positive reward (usually food) for performing the behavior. Initially, behavior that is simply close to what is desired may be rewarded, then gradually the behavior must become more exact to get a reward. So, if you are trying to train an animal to roll over, initially it might get a reward for just laying down, but then it must roll onto it's side to get the reward, then onto it's back, and then right over. The most effective reward for training is food (a favorite treat is best, as long as given in small amounts). This method is much more effective than punishment to shape positive behaviors, because the animals is learning what you want it to do, rather than just what you do not want it to do. On the flip side, if an animal is doing something you do not want it to do, the best remedy is often to withdraw attention, so that the pet does not get any sort of attention for bad behaviors. The theory behind this is that for some animals any attention, even if you are angry or frustrated, is good attention. Therefore, if "punishment" must be used, a time out (e.g. alone in the cage) is perhaps the best route to go.
So back to ferrets. We'll look at litter training for starters.
Litter training is possible, although ferrets do not naturally take to it as well as cats. Providing a stable litter pan that can be firmly attached to the cage is the first step. Start off keeping your ferret and its litter pan in a small area i.e. by confining the ferret in the cage and even blocking off part of the cage if necessary so there is limited space for the ferret to do it's business. Part of the pan must have a low edge to allow the ferret easy access, although part of it can be high walled since ferrets like to back into a corner and may overshoot the edge of a low pan. Do not keep it meticulously clean - placing or leaving a small amount of urine or feces will reinforce that this is a bathroom area (the key being a small amount - the ferret may not use it if it is too dirty). Keep the rest of the cage a sleeping (lots of cuddly bedding) or feeding area. Place the ferret in the litter box before taking it out to play, and return it to the box frequently during play or any time the ferret looks as if it may be getting ready to urinate or defecate.
If you manage to catch your ferret using the litter box, be sure to reward him or her with a treat! If you catch your ferret having an accident, place him or her in the litter box - although this has to be done immediately after having the accident to have any effect at all. Never hit or yell at your ferret, just place him or her in the liiter box.
Once the ferret catches on you can place litter pans in the room(s) in which the ferret plays. You will want to have a few litter pans placed strategically as the ferret is not likely to wander far in search of a bathroom. If you notice a corner or area where the ferret likes to go, that would be a good place for a litter pan. If your ferret picks a place that is not good for you, try placing some food there so that the ferret will think it is an eating area and therefore not a bathroom.
It is a gradual process and since ferrets are not as fastidious as cats, expect some accidents. The key is to reward successes, and never, ever, punish for accidents. Patience and consistency will definitely be necessary. For more help check the Ferret FAQ section on litter training problems.