当前位置: 首页 > 网络学院 > 服务端脚本教程 > ASP > ASP CopyFile 方法
The CopyFile method copies one or more files from one location to another.
ASP CopyFile的作用是将一个或多个文件从一个地址复制到另外一个地址。
FileSystemObject.CopyFile source,destination[,overwrite] |
Parameter参数 | Description描述 |
---|---|
source | Required. The file or files to copy (wildcards can be used} 必要参数。指明要复制的文件(可以使用通配符) |
destination | Required. Where to copy the file or files (wildcards cannot be used} 必要参数。指明文件复制的具体位置(不可以使用通配符) |
overwrite | Optional. A Boolean value that specifies whether an existing file can be overwritten. True allows existing files to be overwritten and False prevents existing files from being overwritten. Default is True |
<% dim fs set fs=Server.CreateObject("Scripting.FileSystemObject") fs.CopyFile "c:mydocumentsweb*.htm","c:webpages" set fs=nothing %> |