Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Copy Folder
Message
 
To
30/10/2006 14:02:41
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01165573
Message ID:
01165593
Views:
16
This message has been marked as a message which has helped to the initial question of the thread.
>Hi,
>
>Can someone provide me a sample for coying a folder using the API ?
>I've been using WSH for this purpose in the last years, but some machines are not allowing WSH for security reasons.
>
>TIA
>
>Cesar

Hi Cesar,
Try this
oShellApp = CreateObject("Shell.Application")
objFolder = oShellApp.NameSpace("C:\Targetfolder")  &&& must exist
*** copy files and subdirs from c:\SourceFolder\ to C:\Targetfolder
objFolder.CopyHere("c:\SourceFolder\*.*")
_______________________________________________________________
Testing displays the presence, not the absence of bugs.
If a software application has to be designed, it has to be designed correctly!
_______________________________________________________________
Vladimir Zografski
Systems Analyst
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform