BluedogLimited™ DavCopy version 1.2

A file copy utility for Windows® SharePoint® Services


Copyright © 2004-2006

Published September 10, 2006

All rights reserved.


Table of Contents

Table of Contents. 1

Description. 1

System Requirements. 1

Setup. 1

Support 1

Operational notes. 2

Command line parameters. 2

Relative source path. 2

Overwriting files. 2

Timeouts. 3

Copy subdirectories. 3

Archived copy. 4

Exclude files and directories. 4

Authentication and user credentials. 4

Copy verification. 5

Return values. 5

Summary Report 5

Sample Output 6



DavCopy.exe is file copy utility which utilizes WebDAV as its transport protocol and is specifically designed to operate against a Windows® SharePoint® Services server.


DavCopy.exe is command line driven. 

System Requirements

.Net Framework v1.1


Copy the executable to a local hard drive.  The tool requires no other setup.


This application is released as-is.  Use at your own risk. 

Please visit for additional help.


Operational notes

Command line parameters

DavCopy.exe requires two command line parameters in order to operate.  Various options can be used to customize behavior.


Usage: DavCopy.exe  <pattern> <destination> [options]





Specifies the file(s) to copy, relative to the current folder.



Specify the destination folder.



Described below…



Relative source path

DavCopy.exe is designed to copy files relative to the current directory. 


The resulting file name is a merge of the two mandatory parameters - <pattern> and <destination>.


For example,


DavCopy.exe test\folder\readme.doc “ documents/”


File ‘readme.doc’ is copied to folder documents/test/folder/


Overwriting files

By default, DavCopy.exe does not overwrite files.  If it finds an existing file at the destination folder, the file will be marked as ‘Skipped’.


The following options can be used to control when and how files are overwritten and/or deleted:





Specify that existing files are to be overwritten.  Files are not deleted beforehand.



Delete the existing file before copying the newer file.


This is useful in situations when you wish to retrigger the “New!” announcement within a SharePoint document library or list.



Performance of the tool is directly related to the amount of bandwidth between you and your server.  Additionally, server use can also affect performance.


The following options can be used to better optimize tool performance:





Specify the amount of time each request is given before a timeout is triggered.



Specify the number of milliseconds to delay between file transactions.


This option is extremely valuable in situations where you are copying a large number of small files.  In such a case, you may run into a problem where a connection failure occurs after a given number of requests have been processed.  This failure point is entirely dependent upon the server’s capacity.


If you find this option is necessary, try small values (i.e. 25-50 ms) and work your way upward.


Copy subdirectories

By default, DavCopy.exe will only copy files contained within the current directory.


The following options can be used to control recursive behavior:





Copies directories and subdirectories except empty ones.



Copies directories and subdirectories, including empty ones.



Archived copy

DavCopy.exe can be instructed to copy only files with the archive attribute set.





Copies only files with the archive attribute set, doesn't change the attribute.



Copies only files with the archive attribute set and then resets (turns off) the archive attribute in the source files.



Exclude files and directories

When using a wildcard file pattern, you may find it helpful to exclude certain files and directories.


The following options can be used to control exclusions:




/XF file [file]

Exclude files matching given names, paths and wildcards.


/XD dir [dir]

Exclude directories matching given names, paths and wildcards.



Authentication and user credentials

By default, DavCopy.exe will use the current user’s credentials for authentication against the target server.  In the event the target server is using either Basic authentication or resides behind a proxy server which does not allow NTLM credentials to pass through, you must provide the credentials.


The following options can be used to specify user credentials:





Specify the user name needed to access the destination.


The user can have the form of 'domain\user' or 'user@fully.qualified.domain'



Password for the associated user account.


If not specified but the ‘/user’ option is used, the user will prompted for a password.



Copy verification

As secondary check to ensure the file was properly copied to the server, the following option can be specified:





Verify file size on server matches the local file size.  If it does not the copying process is terminated.


This is more of a debugging aid.  Please note that using this parameter will result in one additional server query per file; thus, slowing down the entire copy process.



Return values

The following return values are generated:


Return value

Description / Condition


Unexpected exception caused the application to fail.



Help was requested and/or an invalid parameter was provided.



All files and folder were copied and/or created.



Total number of files and folders categorized as ‘Skipped’ or ‘Mismatched’.



Summary Report

Once all files have been processed, DavCopy.exe will produce a summary report.  All transactions are categorized into one of four areas:





Files copied and folders either processed and/or created.



Files which were not copied because …

  • a file with the same name already exists on the server
  • a server connection failure was encountered
  • a folder could not be processed


Folders which were not processed because

  • a server connection failure was encountered
  • could not open a local folder to access permissions
  • invalid characters found in the folder name
  • general web request failures



File on the local system exists as a folder on the server.


Folder on the local system exists as file on the server.



File deleted



The categories are tallied in terms in hit count, time duration, and byte count.

Sample Output

The following example shows how DavCopy.exe reports information.  The output indicates which files were not copied as well as the time and byte count for the each operation category (copied, skipped, mismatched, and deleted).



BluedogLimited (TM) DavCopy v1.2

Copyright (C) 2004-2006 All rights reserved.



Started            : Sunday September 10, 2006 @ 11:20:52:9171

Source folder      : .

File specification : *.htm

Destination folder : http://westgate:8090/test/

Timeout (min)      : 2

Options            : /s /xf *docs\*c* w* /xd reports how-to lang




        Folder           .

100%                8490 anlgform.html


        Folder           docs

100%               10648 alias.html

100%                9699 args.html

100%                7262 debug.html

100%                7572 defns.html

100%                6651 dns.html

                 Skipped domfile.html

                 Skipped errors.html

100%               51756 faq.html

100%               24344 form.html

100%                1825 helpers.html

100%                8235 hierreps.html

100%               38966 indx.html

100%               18108 logfile.html

100%               18618 logfmt.html

100%                4099 lowmem.html

100%                8339 mailing.html

                Mismatch map.html

100%                1911 meaning.html

100%               18132 othreps.html

100%               23727 output.html

100%                3704 Readme.html

100%               15735 reports.html

                 Skipped startux.html

                 Skipped start.html

100%                7414 syntax.html

100%                7884 timereps.html

100%               26503 update.html




                 Total        Copied       Skipped    Mismatched       Deleted

Folders:             2             2             0             0             0

Files  :            28            23             4             1             0

Bytes  :        362482        329622         29486          3374             0

Time   :   00:00:02.15   00:00:03.73   00:00:00.06   00:00:00.01   00:00:00.00


Ended  : Sunday September 10, 2006 @ 11:20:55:0733


The return value is 5, where 4 files were skipped because they previously existed on the server and 1 mismatched file/folder combination was encountered.