here's my tips:
check the nitrate and PH levels of the water. If a fish shows any sign of illness, then isolate it immediately and if possible, take it to your local aquarium for advice on treatment.
Most coldwater fish need air, so ensure that your pump is feeding air into the water.
fish need room to grow. are you overstocking your tank?
is the aquarium you purchase the fish from, reputable? they could be stocking diseased fish
Are you over feeding? If food is left un-eaten, then remove excess food as that will kill them too.
Clean your filters each week and replace per manufacturers recommendations
Check with the aquarium what PH levels your fish requre, as some need different levels to others.
only change a quarter of the tank water at a time, and siphen off faeces from the gravel at least once a week.