There is no need to switch to formula entirely since any amount of your breast milk will have immense benefits for your baby. But it may be necessary to supplement with some formula if you don't have enough milk to meet baby's needs on a particular day. There are many tricks to avoid having this happen though:
1) Try to get a head start by building a stock of breast milk in your freezer before returning to work. This extra "padding" will provide extra peace of mind for you when it comes time to go back to work. Create this stock by pumping at least once per day for a couple of weeks before returning to work. The more time you have to work on this, the better.
2) Be aware of how much milk your baby will need while you are gone. Often care providers are not aware that breastfed babies need far less ounces of breast milk than the typical amount of formula that formula-fed babies need. Your breast milk changes as baby grows, making it a very efficient food. A full supply of breast milk is considered approximately 30 ounces for 24 hours. By figuring out how many times in a 24-hour period your baby eats and dividing 30 ounces by this number of meals, you'll have a good idea of how many ounces your baby takes per feeding. Then consider how many feedings she'll get while you're apart. This will give you an idea of the amount of milk you'll need to leave each day.
3) The more breast milk your baby takes while the two of you are together, the less she'll need while you’re separated. Again, her daily total will be roughly 30 ounces — but this can be portioned out in many ways. Consider working in a few extra feedings while you’re together so that she'll need less while you're apart.
4) Continue to replenish your freezer stock. Continue pumping once or twice per day over the weekends to help replenish your freezer stock, and make it easier for you on those days when you're not able to pump quite as much as you hoped to while at work. A few ounces here and there can make all the difference.