congdantoancau

Detect existed file

Nov 11th, 2021 (edited)
531
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 0.31 KB | None | 0 0
  1. :: https://support.microfocus.com/kb/doc.php?id=7015261
  2.  
  3. echo off
  4. if exist c:\test\file.txt goto yesfile
  5. if not exist c:\test\file.txt goto nofile
  6. goto end
  7. :yesfile
  8. echo FILE EXISTS PROCESSING
  9. goto end
  10. :nofile
  11. echo FILE DOES NOT EXIST PROCESSING
  12. copy f:\PUBLIC\FILES\file.txt c:\test\file.txt
  13. goto end
  14. :end
Advertisement
Add Comment
Please, Sign In to add comment