home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.msdos.batch      Fun with MS-DOS batch files      42,547 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 41,739 of 42,547   
   Anton Shepelev to All   
   Re: Turing-competeness of the batch lang   
   28 Aug 19 00:06:47   
   
   From: anton.txt@gmail.com   
      
   Herbert Kleebauer:   
      
   > > for  %%i in (*.txt) do call set list=%%list%%,%%i   
   >   
   > When  the  line is parsed, %% is replaced by %, so   
   > it becomes:   
   >   
   > call set list=%list%,%%i   
      
   That explains it, but what about the %%i?   I  never   
   understood  why  the  FOR  counter must be specified   
   with % on the command line and with %%  in  a  batch   
   file,  whereas other command (e.g. echo %PATH%) work   
   identically.  Again, the FOR documentation  communi-   
   cates the fact but gives no explanation.   
      
   --   
   ()  ascii ribbon campaign -- against html e-mail   
   /\  http://preview.tinyurl.com/qcy6mjc [archived]   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca