[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Delete a File?

Posted on 2002-03-26
4
Medium Priority
?
170 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 300 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

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

Summary: This tutorial covers some basics of pointer, pointer arithmetic and function pointer. What is a pointer: A pointer is a variable which holds an address. This address might be address of another variable/address of devices/address of fu…
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 opening and reading files in the C programming language.
The goal of this video is to provide viewers with basic examples to understand and use switch statements in the C programming language.
Suggested Courses

867 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