If:then Add 1 to a cell

Microsoft Exchange server 2007 x64 dvd -...
December 30, 2010 at 12:19:48
Specs: Windows XP
 In EXCEL (not VBA nor conditional format)Is there a way to add "1" to a cell value when an "IF THEN" is true?=IF(O53="7",O56=O56+1,"not working")=IF(O53="7",O56+1,"not working")Neither works... it will highlight "O56" but won't change it. Wherever you place the formula the result in that cell is "not working"

See More: If:then Add 1 to a cell

#1
December 30, 2010 at 13:00:26
 An Excel formula can not do anything except return a value in the cell in which it resides. It can not perform an operation on or change another cell.Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

Report •

#2
December 30, 2010 at 13:05:27
 This is fire dept. related. I want to use the indirect formula to see how many cells in a range contain certain text (e.g. "ALS"), There are "ALS" engines and "ALS" trucks. I need to have separate totals. The problem is that the "ALS" total is dependent on the cell above it whether it is an engine or a truck.So, I have to use a different worksheet, add the cells up there and transfer the total. No other way?

Report •

#3
December 30, 2010 at 13:16:08
 I don't know if there is another way because we can't see your spreadsheet from where I'm sitting.There are various ways to SUM and/or COUNT cells based on 2 criteria, but we can't suggest anything unless we know more about how your data is laid out.Can you provide some examples of input and expected output data so that we have something to work with?Read the How To referenced in the following line before posting data.Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

Report •

Related Solutions

#4
December 30, 2010 at 19:14:57
 I decided to go another way and use what you suggested... the SUM function.=SUM(IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!N\$58")="ALS","1","0")+IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!O\$58")="ALS","1","0")+IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!P\$58")="ALS","1","0")+IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!P\$58")="ALS","1","0")+IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!Q\$58")="ALS","1","0")+IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!S\$58")="ALS","1","0")+IF(INDIRECT("'"&TEXT(TODAY()-10,"mm-dd")&"'!W\$58")="ALS","1","0"))Works like a champ! Thanks for the suggestion.

Report •

#5
December 30, 2010 at 21:07:36
 Why are you checking P58 twice?Why do you have quotes around your 1's and 0's?Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

Report •

#6
December 31, 2010 at 06:32:16
 The double reference to N\$58 was a mistake. I was copying and pasting, and didn't realize that I hadn't changed that formula before sending it to you. The quotations around the "1" and the "0"? I guess I originally had text at first and just forgot to remove the quotation marks. Thanks for pointing that out.Scott

Report •