October 25, 2000 - Copying Files
October 25, 2000|
Tips: October 2000
Yehuda Shiran, Ph.D.
copy()method of the
Fileobject. Its syntax is the following:
destination is where you want the file to be copied to, and
overwrite is a boolean argument telling the method whether to overwrite an existing file with the same name (
true) or not (
false). When you specify a false value, the browser will pop up an alert box when you try to overwrite an existing file.
Here is a piece of script that will copy a file from drive c to drive d, and will overwrite any existing files with the same name: