Dessip Posted September 25, 2004 Share Posted September 25, 2004 Hey i am trying to get a command in VB that allows me to copy a actual folder from one place to another, but VB 6 only supports FileCopy which copys a file from one location toanother, i have thought about it useing Shell XCOPY, but the problem is if i do that then i am gonig to need it to report back that it has done so the code can continue to run, Also i dont want to use and Refrences, i would rather use API but i dont know a API call for that only for CopyFile, but i have even tryed FileCopy C:\blah\*.* C:\blah2\*.* but it only copied the files that was in the root of blah folder. Thanks In AdvanceDessip Link to comment Share on other sites More sharing options...
Redman Posted October 5, 2004 Share Posted October 5, 2004 Look here a lot of source code examples.Planet Source CodeRedman Link to comment Share on other sites More sharing options...
TheRookie Posted October 7, 2004 Share Posted October 7, 2004 Try this, Dim fs As Object Set fs = CreateObject("Scripting.FileSystemObject") fs.CopyFolder "C:\Temp", "D:\Temp" Set fs = NothingThis copies all subfolders and files from the first path to the second path, note that both folders must exist. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now