We present experiments on decelerating and trapping ammonia molecules using a combination of a Stark decelerator and a traveling wave decelerator. In the traveling wave decelerator a moving potential is created by a series of ring-shaped electrodes to which oscillating high voltages are applied. By lowering the frequency of the applied voltages, the molecules confined in the moving trap are decelerated and brought to a standstill. As the molecules are confined in a true 3D well, this new kind of deceleration has practically no losses, resulting in a great improvement on the usual Stark deceleration techniques. The necessary voltages are generated by amplifying the output of an arbitrary wave generator using fast HV-amplifiers, giving us great control over the trapped molecules. We illustrate this by experiments in which we adiabatically cool trapped NH3 and ND3 molecules and resonantly excite their motion.