[Remind-Fans] Week Numbers. (2nd try)

Geoff ghubbard at instihost.com
Wed Mar 17 05:26:18 EDT 2010


Where I am at the moment, people tend to specify when things are going to
happen by giving the week number of the year. 
eg: "I'll be away on holiday during week 13."

How do I make remind work sensibly with week numbers?

Here are some things I have tried:

----
# WeekNumbers.rem

# What I think I  want to be able to do:
#REM Week08 OMIT Sat Sun MSG This is week 8

# This works, more or less, but seems hard to use in a generic way
REM Mon Tue Wed Thu Fri SATISFY (weekno(trigdate()) == 09)
IF trigvalid()
	REM [trigdate()] MSG Week 09 Weekday [trigdate()]
ENDIF

# Doesn't work - only gives me the first day of the week.
REM Mon SATISFY weekno(trigdate()) == 10
IF trigvalid()
	REM [trigdate()] *1 UNTIL [trigdate()+4] MSG Week 10. Starts: [trigdate()]
ENDIF

# Doesn't work - only gives me the first day of the week.
REM Mon SATISFY weekno(trigdate()) == 11
IF trigvalid()
	SET week11_start trigdate()
ENDIF
REM [week11_start] *1 UNTIL [week11_start+4] MSG Week 11. Starts: [week11_start]

# Works but requires hardcoded date. 
# Although seemingly the same as for week 11 above?
SET week12_start '2010-03-22'
REM [week12_start] *1 UNTIL [week12_start+4] MSG Week 12. Starts: [week12_start]

----

I don't have to precompute a table of week number start dates do I?

Any clues?

Thanks.

Geoff.




More information about the Remind-fans mailing list