PDA

View Full Version : [SOLVED:] Subtotal??



plasteredric
10-16-2017, 04:27 AM
20664

Im in need of a formula that only includes visible rows so that I can use filters on my sheet to refine an outcome.

attached is sample sheet if anyone can help.

Thanks

mdmackillop
10-16-2017, 05:34 AM
No data to test this on.

plasteredric
10-16-2017, 07:49 AM
No data to test this on.

Not sure what you're looking at but there is data in the sheet where it is needed

p45cal
10-16-2017, 08:58 AM
Not sure what you're looking at but there is data in the sheet where it is neededHe's looking at your attached file. There's no data to test this on.

plasteredric
10-16-2017, 10:27 AM
He's looking at your attached file. There's no data to test this on.

If you look at the attached pic there is data in the cells that are to be referenced

plasteredric
10-16-2017, 11:16 AM
I have this formula for cell 'AH6' which works to count the number or instances in the column, i just don't know how to only count the rows where there is a value in the AH column

=SUMPRODUCT(($Q$30:$Q$9999=$Y6)*(SUBTOTAL(103,OFFSET($Q$30,ROW($Q$30:$Q$999 9)-MIN(ROW($Q$30:$Q$9999)),0))))

p45cal
10-16-2017, 01:01 PM
Not 100% sure what you're after but test this in AH6 copied down and across:
=SUMPRODUCT(SUBTOTAL(3,OFFSET(AH$30,ROW(AH$30:AH$99924)-ROW(AH$30),0)),--($Q$30:$Q$99924=$Y6))

Also test 103 instead of 3.

plasteredric
10-16-2017, 03:56 PM
Not 100% sure what you're after but test this in AH6 copied down and across:
=SUMPRODUCT(SUBTOTAL(3,OFFSET(AH$30,ROW(AH$30:AH$99924)-ROW(AH$30),0)),--($Q$30:$Q$99924=$Y6))

Also test 103 instead of 3.

Thanks, works a treat

mdmackillop
10-17-2017, 02:08 AM
While I have no doubt the solution works, I would not regard testing on 3 unique items a real "test". What is the issue in providing a realistic data sample? Personally, I'm not going to spend my time filling in random data for testing results.