Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Vb6 Help How to Delete Folder

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
jeremydd
Master Cheater
Reputation: 0

Joined: 16 Jul 2007
Posts: 498

PostPosted: Sat Sep 22, 2007 12:55 am    Post subject: Vb6 Help How to Delete Folder Reply with quote

hello guys how can i delete folder i know how to delete files but i dont know how to delete folder
Please give me the code thanks
- jeremydd[/code]

_________________
all people on cheat engine dosent have respect on me So i will never post or visit this forum again this people are no respect T_T
-jeremydd
Back to top
View user's profile Send private message
appalsap
Moderator
Reputation: 0

Joined: 27 Apr 2006
Posts: 6753
Location: Pakistan

PostPosted: Sat Sep 22, 2007 1:37 am    Post subject: Reply with quote

RemoveDirectory

not a vb command, an API
Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 205

Joined: 25 Jan 2006
Posts: 8587
Location: 127.0.0.1

PostPosted: Sat Sep 22, 2007 7:08 am    Post subject: Reply with quote

You can also use the FileSystemObject to remove folders. (And do various other directory related things.)

You need to add the Microsoft Scripting Runtime to your project:
Project -> References and locate 'Microsoft Scripting Runtime' in the list. Then check the checkbox next to it and click ok.

Then your code will be something on the lines of:

Code:
    Dim FSO As New FileSystemObject
    If FSO.FolderExists(YOUR_FOLDER_PATH) Then
        FSO.DeleteFolder YOUR_FOLDER_PATH, True
    End If


Edit the code as needed, change the paths. And you can also remove the true from the DeleteFolder call if you do not wish for the function to force the delete. If you plan on giving people a program that deletes things, I suggest coding in a check to make sure they want to delete it.
Back to top
View user's profile Send private message Visit poster's website
Trow
Grandmaster Cheater
Reputation: 2

Joined: 17 Aug 2006
Posts: 957

PostPosted: Wed Sep 26, 2007 10:01 pm    Post subject: Reply with quote

RmDir(Path)

didnt check if the folder needs to be empty

_________________
Get kidnapped often.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites