dear membersI tried the following code in commentary(to find bars between 2 
dates) as suggested by TJ.
bi=BarIndex();
bi1=ValueWhen(DateNum()=2007-1-1,bi);
bi2=ValueWhen(DateNum()=2007-12-1,bi);
 numbars=LastValue(bi1-bi2);
WriteVal(numbars);
(1)but i got the following error-
 
Error in AFL formula:
bi2=ValueWhen(DateNum()=2007-12-1,bi); 
  numbars=LastValue(bi1-bi2)-------------------------^
Error 29.Variable 'bi2' used without having been initialized.(2)plz in what 
format DateNum accepts the date? whether in quotes?regards mahesh
 

Reply via email to