Article View: borland.public.cppbuilder.nativeapi
Article #6435Re: deleting files in a directory
From: Remy Lebeau (TeamB)
Date: Fri, 06 May 2005 17:39
Date: Fri, 06 May 2005 17:39
18 lines
1544 bytes
1544 bytes
"JoeBlack" <JoeBlack@newsgroups.nospam> wrote in message news:427b78e2@newsgroups.borland.com... > the problem is the line > > wsprintf(szb,"%s%c%c",DirList->Strings[HOMENETWORK],0,0); > > copies a directory name, say "c:\\temp1" into the pFrom string, > when I call the SHFileOperation it deletes the "c:\\temp1" directory. > What I would like to do is delete all its contents but leave the > directory intact. Have youtried specifying a file mask, ie: "c:\\temp\\*.*" ? Have you tried applying the FOF_FILESONLY flag? Gambit
Technical Details
Message-ID:
<427bad9e$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!newshosting.com!nx01.iad01.newshosting.com!diablo.voicenet.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!news-in.nuthinbutnews.com!news-in.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<427b78e2@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,ecd37b850bb40019 X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com> Newsgroups: borland.public.cppbuilder.nativeapi References: <427b78e2@newsgroups.borland.com> Subject: Re: deleting files in a directory Date: Fri, 6 May 2005 10:39:39 -0700 Lines: 20 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1409 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409 NNTP-Posting-Host: 68.69.17.41 Message-ID: <427bad9e$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1115401630 68.69.17.41 (6 May 2005 10:47:10 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!newshosting.com!nx01.iad01.newshosting.com!diablo.voicenet.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!news-in.nuthinbutnews.com!news-in.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail