Jambunathan K <kjambunat...@gmail.com> writes: >> I sometimes have to convert from a date to a week number, > > Try this. > > (org-odt-format-date "<2011-12-31 Sat>" "%U") > (org-odt-format-date "[2011-12-24 Sat]" "%U") > > You can steal the implementation. The functions have nothing to do with > org-odt, btw.
Another way to get the week of the year is: (require 'calendar) (require 'cal-iso) (car (calendar-iso-from-absolute (calendar-absolute-from-gregorian (list month day year)))) -- Georges Ko g...@gko.net 2012-02-03