Sign in to follow this  
Followers 0
darbid

help with copyhere method of shell.Application

2 posts in this topic

I want to copy a directory.

Func _FileCopy($fromFile,$tofile)
Local $FOF_RESPOND_YES = 16
Local $FOF_SIMPLEPROGRESS = 256
$winShell = ObjCreate("shell.application")
$winShell.namespace($tofile).CopyHere($fromFile,$FOF_RESPOND_YES)
EndFunc

In the source directory I will have multiple files. How can I use the above to name the multiple files. I cannot use *.* as the "Local $FOF_RESPOND_YES = 16" does not work when the file already exists in the target.

Share this post


Link to post
Share on other sites



Why not just use the "DirCopy" command. It is much easier and it allows you to copy that folder along with all sub-folders and files from one command.

Note: DirCopy ( "source dir", "dest dir" [, flag] )

See AutoIt Help for more info.

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0