There are two schools of thought on this. One is to rotate almost every time to different classes of drugs (not different brands-- different drugs). The other, a newer theory is to switch wormers annually. In either case, the idea is to reduce the risk of drug resistance developing in parasite species by catching any worms missed in one round by the next. I basically alternate wormers every time I worm, but I am watching the research on the other method to see how it is working and would consider switching if the research supports it.
How often to worm varies by region and management. At the moment, vets are starting to recommend that you worm based on actual egg counts in fecal samples given to your vet. You can put a few fresh horse turds into a ziploc and take it to the vet for a relatively inexpensive test. Some people just worm every 8 to 12 weeks whether the horse needs it or not, but some researchers claim this practice is contributing to increased drug resistance.
As a general rule, ivermectin is the standard wormer, but there are concerns that even it is starting to have issues with parasite resistance, making rotation even more important. it is good to worm at least once a year with a product designed to get tapeworms (praziquantel which is usually sold in a mix with ivermectin like Zimectrin Gold), and to use a non-invemectin-based wormer at least once or twice a year. Farnam's Rotation 2 is one I use, its main ingredient is pyrantel pamoate. Another is Panacur, which has Fenbendazole as its main ingredient. Neither of these will get all the parasites that ivermectin can, but they will nail most of them, plus get any resistant parasites that the ivermectin missed.
Some people use a Moxidectin wormer once or more a year to get encysted small strongyles. It's still an ivermectin family wormer, though, so you still need to rotate out with pyrantel pamoate or fenbendazole. Moxidectin wormers, such as Quest, are also controversial because they really do get almost everything, which in a horse with a high parasite load can actually harm the horse by overloading its system with dead and dying parasites and the toxins those creatures generate. I use Quest as part of my rotation, but I do not use it on a new horse with an unknown parasite history. I usually start a new horse on simple ivermectin unless my vet recommends otherwise (the non-ivermectin wormers are sometimes used to more gently start to unload parasites in badly neglected horses) and personally I don't use moxidectin until I have had the horse under my own management for at least 6 to 9 months.
In short, run stool samples by your vet, and go on the recommendations he or she makes based on your horse and where you live.