Deleting a file

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to delete a file that I created with fopen().
There does not seem to be any fdelete?
What call do you use to delete (also need rename) a file???

Thanks
 
JackieR said:
I am trying to delete a file that I created with fopen().
There does not seem to be any fdelete?
What call do you use to delete (also need rename) a file???

In stdio.h there are remove (it's supposed to be portable) and _unlink.
In windows.h there are DeleteFile and SHFileOperation. In .NET,
System::IO::File::Delete should do it.

Tom
 
To delete use "_unlink" and "rename" to rename the file. Both are defined
in <stdio.h>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top