Solved

Delete a File?

Posted on 2002-03-26
4
164 Views
Last Modified: 2010-04-15
Hi!
How do I delete a file in C?
/Micke
0
Comment
Question by:mickehallgren
  • 3
4 Comments
 
LVL 30

Accepted Solution

by:
Axter earned 100 total points
ID: 6896054
Try remove function:

int remove( const char *path );


0
 
LVL 30

Expert Comment

by:Axter
ID: 6896056
Example:
remove("c:\\backup.bat");
0
 
LVL 30

Expert Comment

by:Axter
ID: 6896058
FYI:
You need to inlcude <stdio.h>
0
 

Author Comment

by:mickehallgren
ID: 6896086
Thanks! I found the answer at the same moment submitted my question... But I'll give you the points anyway.

/Micke
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
Examines three attack vectors, specifically, the different types of malware used in malicious attacks, web application attacks, and finally, network based attacks.  Concludes by examining the means of securing and protecting critical systems and inf…
The goal of this video is to provide viewers with basic examples to understand how to use strings and some functions related to them in the C programming language.
The goal of this video is to provide viewers with basic examples to understand opening and reading files in the C programming language.

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question