Prüfen ob Datei existiert
| ID | 184 |
|---|---|
| Link Reference | Not set |
| Link Credits | Not set |
| Link Technical Documentation | Not set |
| PlCodelang | Batch |
| PlGroup | Filehandling |
| PlItemTitle | Prüfen ob Datei existiert |
| Code | @echo off SET checkFileExists="C:\Temp\myFile.txt" IF exist %checkFileExists% GOTO :EXISTS GOTO :EXISTSNOT :EXISTS echo There it is :-) GOTO :END :EXISTSNOT echo Sorry, the file isn't there :-( GOTO :END :END echo End of program |
| Result Example |