To add what Copperhead has posted: (written from personal experience)
If you do have to go the route of a bankruptcy for what ever reason do not under any circumstance think that your lawyer will follow up on your credit for you.
My wife and I have been through a Chapter 13 and although my lawyer did take care of getting our debts consolidated and into the case they did not tell me of anything to do with credit other than it will stay on your report for 7 years.
What I found out afterwords is that the companies that we were making payments to through the plan sometimes did not report things correctly if at all. When we got out of the bankruptcy there were accounts that still showed a balance on them, accounts that showed us late for 3 years, even though we were making payments to the trustee of the case, etc.
If you have to file, when you get your acceptance into the plan and you have your papers send them off to all your creditors that were named in the bankruptcy. As Copperhead mentioned there are the big 3 credit reporting agencies that in a lot of ways run your life (if you want to purchase anything on credit that is). These agencies used to only deal with consumers by snail mail. You can now create disputes through their websites and these still fall under the FCRA that states the creditor has 30 days to respond to your dispute or it will be removed from your report.
My wife and I were able to bring our credit scores up to 680 (mine) and 715 (hers) within 6 months of being out of our bankruptcy. Although we still have this on our report by making sure all the creditors have updated our accounts correctly it only reports as 1 derogatory instance instead of many. Again, as Copperhead mentioned Debt/Income is a huge part of helping us get loans after this as most banks will not touch debtors for at least 2 years after bankruptcy.
If you are a veteran you can use your VA loan for a home but you have to have a minimum of a 660 (as of Sept 12) credit score.
The first thing I recommend doing once you are done with it (or close to the end) is apply for a card that helps rebuild your credit. Many of these take a deposit (i.e. $500) then give you a $500 line of credit minus their yearly fee. The nice part is that they report to the big 3. This is important as not all banks / etc report to all agencies. Why this is I don't really know but you will find this as you look at your reports.
If you have any more questions for me please don't hesitate to ask. I was very depressed when this happend, and felt that I wasn't a man and really let my family down. I have since realized that I did everything in my power but when the economy took a dive and I was put out of work there was nothing I could do. I have since tried to help others know what to look for from my personal experience.
****I am not a credit professional nor do I claim that everything I say will work or fix your problem. I can only tell you my experiences/choices and what the results were.****