Thanks Abby!
For the cost basis, I use the capital account withdrawal as the ending basis. Not the original amount paid. Then the gain subject to recapture as ordinary income listed in the K-1, is reported on the 4797 as ordinary income, this amount is subtracted from the capital gain amount. Say the Sales Price is 10,000, and the basis is 6,000, and the gain subject to recapture is $3,000, you would have a $1,000 capital gain and a $3,000 ordinary income gain.
For a loss transaction, say the sales price is $10,000 and the basis is $15,000, and the amount subject to recapture is $3,000, you would have a $8,000 capital loss, and a $3,000 ordinary gain on the Form 4797.
I am hoping I am seeing this correctly. Thanks for your help.