Nov 30 2017
12:44 AM
- last edited on
Jul 25 2018
10:30 AM
by
TechCommunityAP
Nov 30 2017
12:44 AM
- last edited on
Jul 25 2018
10:30 AM
by
TechCommunityAP
Hi all
Is this possible?. I would like to add several cells together then add "5" to the total if one cell contains the text 'yes'.
I have so far
=SUM(B1,C1,D1,E1)
please help thanks
Nov 30 2017 01:23 AM
SolutionHi,
Yes, this is possible!
Try this formula:
=IF(SUM(IFERROR(SEARCH("yes",B1:B10),0))>0,SUM(B1:B10)+5,SUM(B1:B10))
NOTE: To enter this formula press Ctrl+Shift+Enter, this keystroke will force the formula to return the right result.
Nov 30 2017 01:30 AM - edited Nov 30 2017 01:41 AM
Hi,
I'm sorry, but do you want to count or sum the cell values?
If you want to count the cells and add 5 to the total only once, you could try this - not the most elegant solution, but it works:
=COUNTA(<your range>)+IF(COUNTIF(<your range>,"Yes"),5,0)
You can substitute <your range> with the cells - either B1:E1, or 1:1 if you are looking to expand it.
If you're looking to sum, use Haytham's solution :)
KR
Nov 30 2017 01:53 AM
Nov 30 2017 02:10 AM
You can also refer it to a cell as follows:
Nov 30 2017 02:21 AM
Nov 30 2017 02:42 AM - edited Nov 30 2017 02:42 AM
In the formula edit mode, replace this operator > with this =
Before
=IF(SUM(IFERROR(SEARCH(E8,B1:B10),0))>0,SUM(B1:B10)+5,SUM(B1:B10))
After
=IF(SUM(IFERROR(SEARCH(E8,B1:B10),0))=0,SUM(B1:B10)+5,SUM(B1:B10))
May 24 2018 11:11 AM
Hi, to all!
You can use this formula (non CSE formula):
=SUM(B1:B10,5*COUNTIFS(B1:B10,"?*",B1:B10,"<>No"))
Blessings!
Jun 13 2018 04:06 AM
Hi,
Is this what you wanted?
Rgds.
Hitesh Gaur
Nov 30 2017 01:23 AM
SolutionHi,
Yes, this is possible!
Try this formula:
=IF(SUM(IFERROR(SEARCH("yes",B1:B10),0))>0,SUM(B1:B10)+5,SUM(B1:B10))
NOTE: To enter this formula press Ctrl+Shift+Enter, this keystroke will force the formula to return the right result.