If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
multiplying a negative time value by a monetary rate
hi there, I have a cell that contains a negative value, which I need to
multiply by a rate. I have set to 1904 system, what I would like to do is if the cell contains a negative value, disregard this and treat it as zero in the calculation. I have tried if statements, but having no luck with it. The formula I have in the sheet is =(DAY(O18)*24*$AM$8)+(HOUR(O18)*$AM$8)+(MINUTE(O18/60*$AM$8))-AL18 where o18 is the negative value and $am$8 is the rate. Cell o18 contains only a time value. the main problem is that this value is the result of a formula, where the result could be either positive or negative. is there a way to modify the above formula to basically disregard negative values but still calculate for positive ones. Any help would be greatly appreciated as I am struggling big time with this --- Message posted from http://www.ExcelForum.com/ |
#2
|
|||
|
|||
multiplying a negative time value by a monetary rate
If I understand you correctly:
=MAX(0, O18 * 24 * $AM$8) - AL18 In article , apogee wrote: hi there, I have a cell that contains a negative value, which I need to multiply by a rate. I have set to 1904 system, what I would like to do is if the cell contains a negative value, disregard this and treat it as zero in the calculation. I have tried if statements, but having no luck with it. The formula I have in the sheet is =(DAY(O18)*24*$AM$8)+(HOUR(O18)*$AM$8)+(MINUTE(O18/60*$AM$8))-AL18 where o18 is the negative value and $am$8 is the rate. Cell o18 contains only a time value. the main problem is that this value is the result of a formula, where the result could be either positive or negative. is there a way to modify the above formula to basically disregard negative values but still calculate for positive ones. Any help would be greatly appreciated as I am struggling big time with this |
Thread Tools | |
Display Modes | |
|
|