I have this piece of code . . .
Code: Select all
for %%R in ("%userprofile%\Desktop\x.txt") do if %%~zR equ 0 del "%userprofile%\Desktop\x.txt"
If the .txt file has data then output the message "The file was created successfully"
If the .txt file doesn't have data then output the message "NO ERRORS FOUND, deleting file.".
I was going to post the things I have tried but there has been quite a few!!!
Thanks in advance.