IF CODE IN ROW, THEN MULTIPLY ADJACENT VALUE BY SPECIFIC COLUMN VALUE IN SAME ROW

RSHVAG

New Member
Joined
Jul 24, 2023
Messages
2
Office Version
  1. 365
Platform
  1. MacOS
Apologies in advance if this isn't well worded.

The sheet below is an abridged version of a much larger document.

Essentially, I'm trying to add up all of the Hours for a specific employee code when multiplied by the value in the final column.

So, for the employee code CD, it would be ((0.1x225)+(0.2x225)+(0.25x100))

Any & all help is welcome...thanks!

Employee 1Hours 1Employee 2Hours 2ANNUAL OUTPUT
NO0NO03
CD0.1TR0.1225
CD0.2TR0.5225
NO0NO00
TR0.25CD0.25100
TR2NO012
CW2TR136
 

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
How do you feel about helper columns?
Book4
ABCDEFGHIJ
1Employee 1Hours 1Calc1Employee 2Hours 2Calc2ANNUAL OUTPUTEmployeesResult
2NO0
3NO00NO003CD92.5
4CD0.122.5TR0.122.5225TR220
5CD0.245TR0.5112.5225CW72
6NO00NO000
7TR0.2525CD0.2525100
8TR224NO0012
9CW272TR13636
Sheet1
Cell Formulas
RangeFormula
J2:J5J2=SUMIF($A$3:$A$9,I2,$C$3:$C$9)+SUMIF($D$3:$D$9,I2,$F$3:$F$9)
C3:C9C3=B3*G3
F3:F9F3=E3*G3
 
Upvote 0
I feel like I should like them...! Thanks. I'll give this a whirl!

Much appreciated!
 
Upvote 0
Hi & welcome to MrExcel.
Another option
Fluff.xlsm
ABCDEFGH
1Employee 1Hours 1Employee 2Hours 2ANNUAL OUTPUT
2
3NO0NO03CD92.5
4CD0.1TR0.1225TR220
5CD0.2TR0.5225
6NO0NO00
7TR0.25CD0.25100
8TR2NO012
9CW2TR136
Master
Cell Formulas
RangeFormula
H3:H4H3=SUMPRODUCT((($A$3:$A$9=G3)*($B$3:$B$9))+(($C$3:$C$9=G3)*($D$3:$D$9)),$E$3:$E$9)
 
Upvote 0

Forum statistics

Threads
1,224,744
Messages
6,180,696
Members
452,994
Latest member
Janick

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