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,792 of 68,980   
   mokomoji to All   
   Re: Get date of recent weekday   
   08 Sep 21 01:40:44   
   
   From: mokomoji@naver.com   
      
   i finded  week friday before   
   i'm happy   
      
   This might not be useful to everyone else, but it's do not worth mentioning.   
   I do not numbered the lines this time because a lot of them will wrap.   
      
   o_o)/)   
      
   ver 4.0   
      
   @echo off   
   setlocal   
   cd /d "%~dp0"   
   for /f "tokens=1* delims==" %%f in (   
   'wmic path win32_localtime get dayofweek /value'   
   ) do (   
   call set z_dayx=%%g   
   call echo ""|call find /v "%%z_dayx%%" 2>nul>nul&&(   
   call set /a "z_value=(%%z_dayx%% %%%% 5)+!(%%z_dayx%% / 5)*2" 2>nul   
   ))   
      
   for /f "tokens=1* delims=-" %%f in (   
   'forfiles /d -%z_value% /c "cmd /c echo @isdir-@file" 2^>nul^|find /i "true"'   
   ) do echo --%%f-%%g--   
   endlocal   
   pause   
      
   --- 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