* diary question
@ 2003-10-31 16:23 Rudy Gevaert
0 siblings, 0 replies; 5+ messages in thread
From: Rudy Gevaert @ 2003-10-31 16:23 UTC (permalink / raw)
Hi
How can I mark al the uneven weeks?
Thanks in advance,
--
Rudy Gevaert rudy@gnu.org
Web page http://www.webworm.org
GNU/Linux for schools http://www.nongnu.org/glms
Savannah hacker http://savannah.gnu.org
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: diary question
[not found] <mailman.2883.1067617940.21628.help-gnu-emacs@gnu.org>
@ 2003-11-04 17:00 ` Edward M. Reingold
0 siblings, 0 replies; 5+ messages in thread
From: Edward M. Reingold @ 2003-11-04 17:00 UTC (permalink / raw)
Cc: Rudy Gevaert
>>>>> "RG" == Rudy Gevaert <rudy@gnu.org> writes:
RG> Hi How can I mark al the uneven weeks?
Do you mean the ISO week numbering? If so, for example, a diary entry for the
Monday of each such week would be
&%%(let* ((iso-date (calendar-iso-from-absolute
(calendar-absolute-from-gregorian date)))
(week (extract-calendar-month iso-date))
(day (extract-calendar-day iso-date)))
(and (= day 1)
(= (% week 2) 1))) Today is Monday of an odd week
--
Professor Edward M. Reingold Email: reingold@iit.edu
Chairman, Department of Computer Science Voice: (312) 567-3309
Illinois Institute of Technology Assistant: (312) 567-5152
Stuart Building Fax: (312) 567-5067
10 West 31st Street, Suite 236
Chicago, IL 60616-3729 U.S.A.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Diary question
@ 2007-03-25 21:24 Steve Brown
0 siblings, 0 replies; 5+ messages in thread
From: Steve Brown @ 2007-03-25 21:24 UTC (permalink / raw)
To: help-gnu-emacs
Hi All,
I can mark the last instance of a particular day using
%%(diary-float t 4 -1)
and alls well, but I get paid on the last working day, and I'd like to
mark it. I would guess that I could change the 4 for a list, but it
didn't work, and now I'm lost.
Anyone got a clue for me?
Thank you, Steve.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Diary question
[not found] <mailman.1494.1175000724.7795.help-gnu-emacs@gnu.org>
@ 2007-03-27 13:26 ` Edward M. Reingold
2007-03-27 19:37 ` Steve Brown
0 siblings, 1 reply; 5+ messages in thread
From: Edward M. Reingold @ 2007-03-27 13:26 UTC (permalink / raw)
To: help-gnu-emacs; +Cc: steve.stevebrown
>>>>> "SB" == Steve Brown <steve.stevebrown@gmail.com> writes:
SB> %%(diary-float t 4 -1)
SB> and alls well, but I get paid on the last working day, and I'd like to
SB> mark it. I would guess that I could change the 4 for a list, but it
SB> didn't work, and now I'm lost.
For example:
&%%(let* ((month (extract-calendar-month date))
(day (extract-calendar-day date))
(year (extract-calendar-year date))
(last (calendar-last-day-of-month month year))
(dayname (calendar-day-of-week date)))
(or (and (= day last) (memq dayname '(1 2 3 4 5)))
(and (or (= day (1- last)) (= day (- last 2)))
(= dayname 5)))) Payday!
Or, if it's the first work day of the month:
&%%(let ((dayname (calendar-day-of-week date))
(day (car (cdr date))))
(or (and (= day 1) (memq dayname '(1 2 3 4 5)))
(and (memq day '(2 3)) (= dayname 1)))) Rent due
--
Professor Edward M. Reingold Email: reingold@iit.edu
Department of Computer Science Voice: (312) 567-3309
Illinois Institute of Technology Fax: (312) 567-5067
Stuart Building, 228F
10 West 31st Street
Chicago, IL 60616-3729 U.S.A.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Diary question
2007-03-27 13:26 ` Edward M. Reingold
@ 2007-03-27 19:37 ` Steve Brown
0 siblings, 0 replies; 5+ messages in thread
From: Steve Brown @ 2007-03-27 19:37 UTC (permalink / raw)
To: help-gnu-emacs
Absolutely superb.
Thank you very much for your fast reply.
Steve
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-03-27 19:37 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-31 16:23 diary question Rudy Gevaert
[not found] <mailman.2883.1067617940.21628.help-gnu-emacs@gnu.org>
2003-11-04 17:00 ` Edward M. Reingold
-- strict thread matches above, loose matches on Subject: below --
2007-03-25 21:24 Diary question Steve Brown
[not found] <mailman.1494.1175000724.7795.help-gnu-emacs@gnu.org>
2007-03-27 13:26 ` Edward M. Reingold
2007-03-27 19:37 ` Steve Brown
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.