onestar
asked on
delete a file in dos
I am writing a program to be run in dos.
How can i delete a file using c++?
Example if i was in dos
del junk.txt
I want to write a program to do that.
How can i delete a file using c++?
Example if i was in dos
del junk.txt
I want to write a program to do that.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Here is another way. Use the system function.
#include <stdlib.h>
void main()
{
system("del junk.txt");
}
#include <stdlib.h>
void main()
{
system("del junk.txt");
}
ASKER