Advertisement
Guest User

Untitled

a guest
Apr 13th, 2017
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @echo off
  2. setlocal enabledelayedexpansion
  3. if "%~1"=="" goto noparam
  4. if not exist "%~1\ " goto nocatalog
  5. if not exist "%~1\numb.txt" goto nofile
  6. for /F %%i in ('type "%~1\numb.txt" ^| findstr /rc:"[0-9]"') do (
  7.  set /a n=%%i %% 5
  8.  if "!n!"=="0" echo %%i
  9. )
  10. exit /b
  11. :nocatalog
  12. echo "Заданная папка не найдена"
  13. exit /b
  14. :nofile
  15. echo "Файл не найден"
  16. exit /b
  17. :noparam
  18. echo "Не задано имя папки"
  19. exit /b
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement