You may want to use cwd in your program, then use system(). Beware of the fact that on most systems (and i suspect Win32 too) system() opens a new shell for each call. So, your first would chage directory and then close, and your second would delete files in the current directory.
As a side note, if you are deleteing files you may want to look at unlink, which will let you check the status of your deletes. (glob + unlink = gooood)
In reply to Re: Problem with system ()
by MZSanford
in thread Problem with system ()
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |