countIF or sumproduct?

jakelake

New Member
Joined
Sep 12, 2016
Messages
9
Hello,

I have a table with columns that show how many bike tires I need each week. The rows in the t able are the various types of tires. I am trying to come up with a formula that counts the number of shortages. I have been able to set up conditional formatting to identify the shortages, but I cant get a formula to count.

Qty of Tire A: 2
Qty of Tire B: 2


ABC
1TireQty
2Tire A2
3Tire B2
4Shortage:
01
5Tire TypeWeek 1Week 2
6Tire A
21
7Tire B02

<tbody>
</tbody>

I am trying to find a way to have Row 1 calculate the shortages. As I said, with conditional formatting I can do the formula =SUM($B6:B6)>=$B2

Conditional formatting will automatically change the row and column based on the cells the formatting is being applied too. How do i do this with a formula? I assume I need to use an array or sumproduct. However, I am struggling to think it through or get it to work.

Any ideas?
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
row 1 to show what exactly - total shortage of each week

in B6 and B7 - should =4
in C6 and C7 - should =4
etc
what do you need in row
you could do
=(B6+B7)-4 will give you the shortage
or do you want to see the types of tyre that are short and where would those results go ?

=(B6+B7)>=(B2+B3)
 
Upvote 0
Hello :)
use this formula in C6 and drag down till C7
Code:
=IF(B6>=B2,B6-B2,"")
 
Upvote 0

Forum statistics

Threads
1,214,975
Messages
6,122,538
Members
449,088
Latest member
RandomExceller01

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top