Av8tordude
Well-known Member
- Joined
- Oct 13, 2007
- Messages
- 1,075
- Office Version
- 2019
- Platform
- Windows
This code displays my Win/Loss Percentage. I'm using an auto-filter macro to filter data and I would like to show my Win/Loss percentage on visible rows only. Can someone assist.
Thank you kindly.
Thank you kindly.
Code:
With WorksheetFunction
CCI = Format(.CountIf(Range("P18:P" & LRow), ">" & 0) / .Count(Range("P18:P" & LRow)), "0%") & " / " & Format(1 - .CountIf(Range("P18:P" & LRow), ">" & 0) / .Count(Range("P18:P" & LRow)), "0%")
End With