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,310 of 68,980   
   Docfxit to All   
   Re: Batch file not working correctly   
   27 Sep 18 10:19:29   
   
   From: docfxit@gmail.com   
      
   That helped greatly.   
   I have added the cd\ and the \ in front of desktop.ini   
   I also discovered the attrib was removing the hidded attribute.   
   The dir command was listing only files that were hidden.  I have removed that   
   option.   
   With the changes in the bat file, it is currently deleting all desktop.ini   
   files. It is not successful in deleting the $Recycle.Bin.   
   NOTE: I do expect Win7 will recreate the   
   Here is the latest version:   
      
   @echo on   
      
   Set Drive=E:   
   %Drive%   
   cd\   
   attrib -r -s -h -a "\desktop.ini" /s   
   @for /f "usebackq delims=|" %%i in (`dir /s /b /x ^| find "desktop.ini"`) do (   
   	del "%%i"   
   	Echo "%%i"   
   	)   
   for /f  %%i in ('dir /s /b /x \desktop.ini') do echo %%i   
   cd\   
   attrib -r -s -h -a "\$Recycle.BIN"   
   @for /f "usebackq delims=|" %%i in (`dir /s /b /x  ^| find "$Recycle.BIN"`) do   
   (   
   	Del "%%i"   
   	Echo "%%i"   
   	)   
   @echo Deleting complete, press any key to exit.   
      
   --- 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