IF to compare date with current date and return result

I am looking for a formula that allows me to look at a cell and check whether it is greater than or equal to today's date and return a formulated result, such as "overdue." If it is empty to return another word or nothing.

I tried to copy the result from the source cell ( O10 ) to another cell ( Y10 ) and used the if statement, but this seems too time consuming - should there be a way to read information from the source cell? See below. It also returns expiration when the cell is empty :(

 =IF(O10>Y10,"OVERDUE","NOT DUE") 
+7
source share
3 answers

You can enter the following formula in the cell where you want to see the result of Overdue or Not due :

 =IF(ISBLANK(O10),"",IF(O10<TODAY(),"Overdue","Not due")) 

This formula first checks to see if the source cell is empty. If so, then the result cell will be filled with an empty string. If the source is not empty, then the formula checks if the date is in the source cell before the current day. If so, then the value is set to Overdue , otherwise it is set to Not due .

+14
source

I think this will cover any possible scenario for what is in O10:

=IF(ISBLANK(O10),"",IF(O10<TODAY(),IF(TODAY()-O10<>1,CONCATENATE("Due in ",TEXT(TODAY()-O10,"d")," days"),CONCATENATE("Due in ",TEXT(TODAY()-O10,"d")," day")),IF(O10=TODAY(),"Due Today","Overdue")))

For dates until today, he will tell you how many days the goods should arrive. If O10 = today, then today will be indicated. All that has passed today, and it will read by the deadlines. Finally, if it is empty, the cell will also look empty. Let me know what you think!

0
source

This is just the type of formula I was looking for for Blake, except that it does not give the expected result, but I'm not smart enough to fix it.

Today's date returns “Deadline today” - the correct date of yesterday returns “Deadline 1 day” - it should be “Expired” incorrectly

I understand that the formula needs to be exchanged somewhere, but I cannot fix it successfully

0
source

Source: https://habr.com/ru/post/924813/


All Articles