T
Thomas Peters
I am having difficulty understanding how to formulate multiple nested IF
statements in order to produce the precise result based on the conditions. My
first stumbling block is knowing where to place the parentheses to establish
the precedence of the conditions to be evaluated i.e. if the first
logical_test is FALSE, the second IF statement is evaluated, and so on.
..:Rationale:.
The purpose of this function is to display a value (i.e. string of text,
date/time, or NULL) in the adjacent cell when the user selects one of the
items in the list. In this case, the drop-down list resides in cell D4 and
generates a value in cell E4.
..:Version 1.0:.
In cell D4 there is a drop-down list containing 3 elements:
-Select Status (“Select Status†is default text that the use can see)
-Submitted
-Not Returned
..:Conditional Results Anticipated:.
If D4=“Select Statusâ€, then E4=â€â€
If D4="Submitted", then E4=display the date & time
If D4="Not Returnedâ€, Then E4=â€-“
The IF statement below resides within the cell E4 and simply displays the
results based upon which item in the drop-down list in cell D4 was selected.
However, the problem with using the “NOW() or TODAY()†function is that they
both continue to update and as found out is not static.
=IF(D4="Submitted",NOW(), IF(D4="Not Returned", "-", IF(D4="Select
Status","")))
..:Version 2.0:.
In version 2 I tried a work around by inserting a static date & time
manually by selecting F4 and hitting Ctrl+:, Ctrl+Shift+: and this made the
time stamp static, but to me, it contradicted the point of the function:
=IF(D4="Submitted",F4, IF(D4="Not Returned", "-", IF(D4="Select Status","")))
..:Version 3.0:.
I was able to convert the NOW() function result into text and only update if
E4=â€â€ (TRUE)
=IF(D4="Submitted",E4="",TEXT(NOW(),"mm/dd/yy h:mm AM/PM"))
I have tried to nest the IF statements with the remaining 2 items in the
drop-down list and can not get it to work. Here are a few examples I have
tried and don’t work.
1. =IF(D4="Submitted",E4="",TEXT(NOW(),"mm/dd/yy hh:mm"), IF(D4="Not
Returned", "-", IF(D4="Select Status",""))))
2. =IF(AND(F4="", E4=""),E4='',TEXT(NOW(),"mm/dd/yy hh:mm")))
3. =IF(AND(D13="Submitted",D13<>"Select Status"),E13="",TEXT(NOW(),"mm/dd/yy
h:mm AM/PM"))
Please explain how to nest IF statements or provide any URL’s etc, as I have
searched the web high & low and had no luck in finding any meaningful
information. Oh…don’t forget to show me the right way to compile this
formula. Thanks.
statements in order to produce the precise result based on the conditions. My
first stumbling block is knowing where to place the parentheses to establish
the precedence of the conditions to be evaluated i.e. if the first
logical_test is FALSE, the second IF statement is evaluated, and so on.
..:Rationale:.
The purpose of this function is to display a value (i.e. string of text,
date/time, or NULL) in the adjacent cell when the user selects one of the
items in the list. In this case, the drop-down list resides in cell D4 and
generates a value in cell E4.
..:Version 1.0:.
In cell D4 there is a drop-down list containing 3 elements:
-Select Status (“Select Status†is default text that the use can see)
-Submitted
-Not Returned
..:Conditional Results Anticipated:.
If D4=“Select Statusâ€, then E4=â€â€
If D4="Submitted", then E4=display the date & time
If D4="Not Returnedâ€, Then E4=â€-“
The IF statement below resides within the cell E4 and simply displays the
results based upon which item in the drop-down list in cell D4 was selected.
However, the problem with using the “NOW() or TODAY()†function is that they
both continue to update and as found out is not static.
=IF(D4="Submitted",NOW(), IF(D4="Not Returned", "-", IF(D4="Select
Status","")))
..:Version 2.0:.
In version 2 I tried a work around by inserting a static date & time
manually by selecting F4 and hitting Ctrl+:, Ctrl+Shift+: and this made the
time stamp static, but to me, it contradicted the point of the function:
=IF(D4="Submitted",F4, IF(D4="Not Returned", "-", IF(D4="Select Status","")))
..:Version 3.0:.
I was able to convert the NOW() function result into text and only update if
E4=â€â€ (TRUE)
=IF(D4="Submitted",E4="",TEXT(NOW(),"mm/dd/yy h:mm AM/PM"))
I have tried to nest the IF statements with the remaining 2 items in the
drop-down list and can not get it to work. Here are a few examples I have
tried and don’t work.
1. =IF(D4="Submitted",E4="",TEXT(NOW(),"mm/dd/yy hh:mm"), IF(D4="Not
Returned", "-", IF(D4="Select Status",""))))
2. =IF(AND(F4="", E4=""),E4='',TEXT(NOW(),"mm/dd/yy hh:mm")))
3. =IF(AND(D13="Submitted",D13<>"Select Status"),E13="",TEXT(NOW(),"mm/dd/yy
h:mm AM/PM"))
Please explain how to nest IF statements or provide any URL’s etc, as I have
searched the web high & low and had no luck in finding any meaningful
information. Oh…don’t forget to show me the right way to compile this
formula. Thanks.