With a short sale, your credit will not be as severely impacted as with a forecosure - but do not mistaken - it will be impacted. But because the drop in your score is less with a short sale, you just may have the opportunity to repair your damaged credit more quickly and thus get back into the housing market that much more quickly.
However. Your lender has to agree to a short-sale. You may have to provide some pretty solid and compelling evidence that you are and will be unable to make payments, that your property is in need of repairs you are unable to afford, that you are impacted due to a distressed housing and/or employment market. In "short", you will need a good reason as to why the the lender should agree to your short sale.
Because a foreclosure can be an expensive legal process for lenders, they may be willing to work with you; but again, you will have to make your case.
Another issue to worry about in a short sale (and with a foreclosure, too) is the possible impact the forgiven debt can have on your income tax. Forgiven debt can be considered income and can thus create tax implications. Your lender will issue a 1099 for the forgiven portion, so it will be recorded. That would be the last thing you need when you are already in financial straits, so be sure you understand the terms of your mortgage and talk to a financial adviser before proceeding with either avenue.
Best of luck to you.