问:如何为“OVERDUE”列创建宏(有什么想法?)?
如果满足以下条件,则应为“Y”:
CREATED column+DAYS column is YOUNGER than the current date.
如果不是,它应该是“N”。
但是:周末不需要计算..
所以如果例如:
“CREATED”是“8/10/2013 22:38” - 星期六所以周末,“DAYS”是2,那么两者的加法应该是:8/13/2013 24:00
如果 "CREATED" 是 "8/16/2013 11:26" - Friday, 所以 weekday 并且 "DAYS" 是 2,那么两者的相加应该是:8/20/2013 13:34
例子:
today is: 8/13/2013 10:25
CREATED DAYS OVERDUE
8/10/2013 22:38 2 Y
8/12/2013 11:26 2 N
因为:
8/10/2013 22:38 + 2 days is younger then 8/13/2013 10:25, so "OVERDUE" needs to be "Y"
8/12/2013 11:26 + 2 days is older then 8/13/2013 10:25, so "OVERDUE" needs to be "N"