I have a formula but need something else from it

richard hales

Board Regular
Joined
Feb 18, 2009
Messages
55
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
Good evening everyone

I have this formula which works great but I want it to do something else
=IF(COUNTA(B4:B7),SUMPRODUCT(SUMIF('cmart code'!D2:D15,B4:B7,'cmart code'!E2:E15)),"")
Sheet1. B4:B7 is where the formula looks for a code
Sheet2. 'cmart code'!D2:D15 is the lookup code in this case it’s D2=service1 to D15= service14.
'cmart code'!E2:E15)),"") E2=1 E15=14 and if nothing is entered in B4:B7 it returns a blank cell, in Sheet2. Cell B15.
Now if any one can help me please what I need it to do now is:
D2=service1 to D15= service14 to stay the same but E2=1 E15=14 to change to GF
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
from the way you've explained it, what you need to do is merely edit the E-column Range to have the alpha characters "GF" in them.
 
Upvote 0
thanks for the reply nbrcrunch, i changed the E-column to GF but in Cell B15 it returns a 0 am looking for it to return GF or stay blank.
 
Upvote 0
The objctive is not very clear...

If you want to copy the formula across with the sum range changing...

=IF(COUNTA($B$4:$B$7),SUMPRODUCT(SUMIF('cmart code'!$D$2:$D$15,$B$4:$B$7,'cmart code'!E$2:E$15)),"")

If you want it to have GF2:GF15 as the sum range, use an adjusted copy of the formula:

=IF(COUNTA(B4:B7),SUMPRODUCT(SUMIF('cmart code'!D2:D15,B4:B7,'cmart code'!GF2:GF15)),"")

If the foregoing is of no help, try to elaborate on your objective.
 
Upvote 0

Forum statistics

Threads
1,214,588
Messages
6,120,409
Members
448,959
Latest member
camelliaCase

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