The best thing to do is AVOID foreclosure. If you are having trouble affording your mortgage, there are a few options you should try:
1. Short Sale
2. Loan Modification
Since the Debt Relief Act passed in 2007 any homeowner that sells their primary residence via short sale is not responsible for tax implications or loss incured by the lender.
A loan modification may help make the loan affordable, but you will usually have to pay a fee for this service. Try www.NationalShortSaleOffice.com
. They are one of the less expensive companies out there and are reputable.