Re: [NTG-context] Problem with \date command

2010-10-15 Thread Cedric Mauclair
Right, I forgot about the catcodes. Thank you. -- Cédric On Fri, Oct 15, 2010 at 15:37, Peter Münster wrote: > On Fri, Oct 15 2010, Cedric Mauclair wrote: > >> Any ideas? > > Test file: > > \def\mydate{\doifnextcharelse\space\domydate\domydate } > \def\domydate #1/#2/#3{\date[d=#1,m=#2,y=#3][w

Re: [NTG-context] Problem with \date command

2010-10-15 Thread Peter Münster
On Fri, Oct 15 2010, Cedric Mauclair wrote: > Any ideas? Test file: \def\mydate{\doifnextcharelse\space\domydate\domydate } \def\domydate #1/#2/#3{\date[d=#1,m=#2,y=#3][weekday,day+,month,year]} \starttext \mydate 2/1/2011 \par % token #3 = 2 \mydate 2/1/2 \par % token #3 = 2 \mydate 2/1/

Re: [NTG-context] Problem with \date command

2010-10-15 Thread Cedric Mauclair
I use the minimal from 3 days ago. Here is what I do actually. \def\mydate{\doifnextcharelse\space\domydate\domydate } \def\domydate #1/#2/#3{\date[d=#1,m=#2,y=#3][weekday,day+,month,year]} \mydate 2/1/2011 --> Friday 2 january 2011 \date[d=2,m=1,y=2011][weekday,day+,month,year] --> Sunday 2 jan

Re: [NTG-context] Problem with \date command

2010-10-15 Thread Peter Münster
On Fri, Oct 15 2010, Cedric Mauclair wrote: > > Today I wanted to use the command "\date[d=15,m=10,y=2010][weekday]". > It gives "Friday" as it should. However > "\date[d=2,m=1,y=2011][weekday]" gives the same result which is wrong > (it's a Sunday). In fact, whatever the supplied date, it gives >

[NTG-context] Problem with \date command

2010-10-15 Thread Cedric Mauclair
Hi all, Today I wanted to use the command "\date[d=15,m=10,y=2010][weekday]". It gives "Friday" as it should. However "\date[d=2,m=1,y=2011][weekday]" gives the same result which is wrong (it's a Sunday). In fact, whatever the supplied date, it gives "Friday". I guess the parameter isn't taken int