A. I recently received an email message from a reader who had the belief that a script couldn't copy files over 4GB in size. I decided to test whether this was true.
First, I created a 5GB file by using this command:
D:\temp>fsutil file createnew orig.file 5000000000Then I wrote the following short script to copy a named file:
On Error Resume Next 'Connect to file system object. set objFSO=CreateObject("Scripting.FileSystemObject") If objFSO.FileExists(objVHD.HardDisk.file) Then objFSO.CopyFile WScript.Arguments(0), WScript.Arguments(1) End IfThe VBScript script copied the 5GB file just fine. The 4GB limitation could have been because it was copying to a FAT32 partition or because differently formatted drives might use different amounts of disk space while storing the same amount of data.
0 comments
Hide comments