Let us assume we have the following directory structure:. Then we are forced to delete all the files in folders Precious Data Folder 1 and Precious Data Folder 2 first, then remove these two directories, and finally, we can handle the Release folder itself. Hence we have to solve the problem recursively. The code snippet below demonstrates how to use CFileFind class to do the job and you may need some time to digest it if you are really a beginner.
However, there exists a chance when the user may have some value data in there. We have two choices about the empty folders: keep or remove them. If the end user checks the checkbox "Keep empty folders",. There are some good reasons to keep them, though.
In this case, I require my test application's Release folder to be there. Now let us go back to handle intermediate files which reside in the workspace directory.
By definition,. One thing first: we may have a workspace containing two or more projects, each residing in its own sub folder. If so, we have a bunch of. But we always have one and only one. In this case, workspace directory is the directory containing the. You may ask when the intermediate files are generated in the workspace directory. By default, the files are put in the Recycle Bin, but you can configure DirClean to just delete the files instead. DirClean uses the SHFileOperation function to delete files, so if there are a lot of files to delete, you'll see the familiar flying-paper progress dialog.
The settings here should be self-explanatory. Note that you can override the "Send files to the Recycle Bin" setting by holding down the Shift key when clicking "Clean up temp files. On the NT-based OSes, the way that the shell handles extensions of more than 3 characters will cause problems for C projects. RESX files it only compares the first three characters , and deleting the. RESX files will delete some resource information.
See KB article Q for more info on this feature. Oct 28, - Default list of wildcards updated. Dec 25, - Added note about the Win95TruncatedExtensions registry entry. This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves.
If in doubt please contact the author via the discussion board below. Sign in Email. Forgot your password? Search within: Articles Quick Answers Messages. Tagged as VC6. Stats Michael Dunn Rate me:. Please Sign up or sign in to vote.
A shell extension that deletes compiler temp and intermediate files. The "DirClean options" menu item brings up the DirClean options dialog: The settings here should be self-explanatory. Important note for VS. History Oct 28, - Default list of wildcards updated. A list of licenses authors might use can be found here. Michael lives in sunny Mountain View, California. He pretty much taught himself Windows and MFC programming, and in he designed and coded a new interface for Norton AntiVirus Mike has been a a developer at Napster and at his own lil' startup, Zabersoft, a development company he co-founded with offices in Los Angeles and Odense, Denmark.
Mike is now a senior engineer at VMware. He would get his own snooker table too if they weren't so darn big! He is also sad that he's forgotten the languages he's studied: French, Mandarin Chinese, and Japanese. Southmountain 3-Feb Copy Code.
Jeffrey Walton Jul Kevin Gutteridge Jul Jeffrey Walton 8-Jun Michael Dunn 9-Jun CPallini 2-Apr Opening VS installer will prompt you to download and install the VS freshly because all the folders will be left empty after performing thise steps. Cleaning up corrupt Visual Studio instances Heath.
Heath Stewart September 18, New vswhere: now with more properties! Read about all the new properties output by vswhere. Heath Stewart October 12,
0コメント