That sounds just like my house I sold in CA. I bought it in 1999 for $172K and sold it in 2005 for $575K. It is now on the market as a foreclosure for $159K.
Just like super said, talk to your attorney and CPA. In the past when companies had losses, if they could not write off all the losses in the first year they could carry them over and use the unused losses in future years. This might work for you since it was an investment,Good Luck!
_________________________
There are no shortcuts to any place worth going. (Beverley Sills)