I want to empty a file and i got 2 ways :
1) Using CreateFile function with dwCreationDisposition = TRUNCATE_EXISTING !
2) Opening the file ,setting the file pointer to the beginning of the file with SetFilePointerEx and then calling SetEndOfFile !
Is there any difference and which one should i use ?