Possible Duplicate:
The process cannot access the file because it is being used by another process
I have a PDF file in my application i want to delete that file. when I try to delete the file it give the error "The process cannot access the file because it is being used by another process."
The code is as follows
if (File.Exists(sDownloadFile))
File.Delete(sDownloadFile);
How can I delete this file?