-
A Qn on VB6
I have a question on visual basic 6 and need your help :)
I am making a tiny program to clean up junk files but can't find a good way to remove folders that contains folders and files. I am a beginner and I don't wish to use any API for this.
I want to delete every files individually use the 'kill' function after cleaning up the content of the file.
I am using a DirListBox and a FileListBox to find and remove files and empty folders.
Does anyone know how can I remove folders that contains folders and files? I have been looking for ways to do this using the DirListBox and FileListBox but it is too complicated for me as a beginner. Any helps will be greatly appreciated.
::jumpto::
-
Why use VB when you can use a simple batch file?
See this thread for the batch file programmation - http://www.antionline.com/showthread...hreadid=257320
In batch file, you can use the deltree option to delete folder with subfolder.
-
Quote:
Originally posted here by SDK
Why use VB when you can use a simple batch file?
Why not give the guy the answer he wanted. Damn man...
Instead of useing Kill (file_path) use RmDir for directories
Then use... If Dir (The_File_or_filepath) <> Empty = false Then msgbox "file not found blah blah blah" ,vbcritical "Screw batch files"
You know to sort of check if files exist. There you have it... no lame batch files needed.