home bbs files messages ]

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

   alt.msdos.batch.nt      Fun with Windows NT batch files      68,980 messages   

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

   Message 67,633 of 68,980   
   Mike Sanders to Kenny McCormack   
   Re: Two simple, but related questions ab   
   08 Oct 20 19:36:17   
   
   2a78111a   
   From: mike@porkchop.bsd   
      
   Kenny McCormack writes:   
      
   >1) Is there a simple way to get the number of args passed to a batch (.BAT   
   >    or .CMD) file?  Like $# in Unix.   
      
   How about:   
      
   @echo off   
      
   set argc=0   
   for %%x in (%*) do set /a argc+=1   
      
   echo %argc%   
      
   --- 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