Real property llc claiming LT cap gains ans bus income deductions( $0 income 1 yr) passing through to personal income at the same time.

Can an llc that buy and sells and rents real property ( homes) treat the property sale gains as long term cap gains and  treat all the bus expenses of maintaining the properties, preparing for sale, research, etc as deductions  against income? If there is no llc income one year, can the expenses still of set other income from the filers (my) return such as w2 income since it passes through?