Archive: Clear a file


Clear a file
Hello,

What is the easiest way to clear a file???
How can i delete the whole content of a text file???

thanks for help!


FileOpen $0 $INSTDIR\file.dat w
FileClose $0

should do the trick


Overwrite it with an empty file or open it with FileOpen in "w" mode and close it immediately with FileClose.


okay, thank you very much for your fast answer

thanks aemik