Chapter 7 bankruptcy may be the only way to quickly eliminate all of your outstanding debt. However, it does hurt your credit score. How can you rebuild your score after using bankruptcy?
The first thing to do is to commit yourself to paying every bill you still have on time, every time. Do not rack up high balances on any cards you happen to retain or that you get after the bankruptcy. Pay the rent, pay your mortgage and pay your phone bill. Create a budget and stick to it so that you never have outstanding debt again.
This doesn't mean debt can't help you. Taking on debt and then paying it off builds your score back up. Perhaps the best way to do this is to use a secured credit card. These are typically far easier to get than traditional cards because they require a down payment. Get a card and start using it for your necessary, everyday purchases.
Another potential option is to go on someone else's account, either by signing onto a credit card account as an authorized user -- parents often do this for their children -- or by having someone else co-sign a loan for you. This does mean that person takes on some level of risk. However, it gets your foot in the door with new debt, and you can pay it off responsibly to build your score up again.
These three steps can help you get started. Make sure you consider every aspect of your financial position, including Chapter 7 bankruptcy and all of your legal options.