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 40,590 of 42,547   
   Guy to REJEKTO   
   Re: findstr or parsing   
   07 Dec 12 17:24:42   
   
   From: Use-Reply-To-Address-Header@[127.1]   
      
   REJEKTO wrote:   
      
   > I have manage to finally parse a file to the barest. All I have   
   > now is the following samples:   
   >   
   > (W3SVC/34945844)   
   > (W3SVC/54452847)   
   > (W3SVC/14932848)   
   > (W3SVC/34932849)   
   >   
   > I would like to go one more step further and parse everything out   
   > except the (site) numbers.   
   >   
   > The result would be directed to a txt file and only shows the site   
   > #. Line by line with no spaces. Example below.   
   >   
   > 34945844   
   > 54452847   
   > 14932848   
   > 34932849   
   >   
      
      
   Try...   
      
   FOR /F "tokens=2 delims=/)" %I IN (file) DO @ECHO %I   
      
   $ TYPE file   
   (W3SVC/34945844)   
   (W3SVC/54452847)   
   (W3SVC/14932848)   
   (W3SVC/34932849)   
   $ FOR /F "tokens=2 delims=/)" %I IN (file) DO @ECHO %I   
   34945844   
   54452847   
   14932848   
   34932849   
      
   $   
      
   --- 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