Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Now copy and past the search report results into a batch file named copysrc.cmd.  This Windows console script uses batch commands and the robocopy utility to copy just the desired files from folder ...\ABC\.. to folder ...\clean\....  Note a .* copy is used to get both frm and frx files.

Code Block
if exist copysrc.log del copysrc.log

call :copysrc "C:\gmClients\ABC\src\Dlls\WFCore\frmError.frm"
call :copysrc "C:\gmClients\ABC\src\Dlls\AppMgrs\frmStatus.frm"
...
call :copysrc "C:\gmClients\ABC\src\Dlls\HttpRequestDLL\HttpRequestPay.vbp"
call :copysrc "C:\gmClients\ABC\src\Screens\Corporation\Corp.vbp"
exit /b

::-------------------------------------------------------
:copy1src
::-------------------------------------------------------
@echo off
::echo full path : %~f1
::echo drive : %~d1
::echo path : %~p1
::echo file name only : %~n1
::echo extension only : %~x1
::echo expanded path with short names: %~s1
::echo attributes : %~a1
::echo date and time : %~t1
::echo size : %~z1
::echo drive + path : %~dp1
::echo name.ext : %~nx1
::echo full path + short name : %~fs1

set src=%~p1
set dst=%src:ABC=clean%
set srcfldr=%src:~0,-1%
set dstfldr=%dst:~0,-1%
set filnam=%~n1
echo robocopy "%srcfldr%" "%dstfldr%" "%filnam%.*"
robocopy "%srcfldr%" "%dstfldr%" "%filnam%.*">>copysrc.log

exit /b

:end

...