|
-
July 22nd, 2011, 01:23 PM
#1
Help in File Info
Hi, i am very new to VB. I am working on file operation such as show files, copy file, delete file, show current directory, rename folder, make folder.
My problem right now is with delete and copy file. I have a method of delete and copy but i dont know how to pass this method on a button.
Because we are told that each file operation should have a button for their specific purposes.
Here is my simple gui with 3 buttons which i have made so far. I am using vb2010.
http://www.flickr.com/photos/tiwnet/5964183989/
Public Sub DeleteFilesFromFolders(ByVal sourcePath As String)
If (Directory.Exists(DirPath)) Then
For Each fName As String In Directory.GetFiles(DirPath)
If File.Exists(fName) Then
File.Delete(fName)
End If
Next
End If
End Sub
Hope you could help me. tnx in advance.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|