当前位置: 首页 > 网络学院 > 服务端脚本教程 > ASP > ASP CopyFolder 方法

ASP
ASP Drive
ASP File
ASP Folder
ASP Dictionary
ASP ADO
ASP AdRotator
ASP BrowserCap
ASP Content Linking
ASP Content Rotator
ASP Quick Ref
ASP 摘要
ASP 实例

ASP CopyFolder 方法


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-03-04   浏览: 359 ::
收藏到网摘: n/a

The CopyFolder method copies one or more folders from one location to another.
CopyFolder的作用是将一个或多个文件夹从本地复制到其他地方。

Syntax
语法

FileSystemObject.CopyFolder source,destination[,overwrite]

Parameter参数 Description描述
source Required. The folder or folders to copy (wildcards can be used)
必要参数。指明要复制的文件夹(可以使用通配符)
destination Required. Where to copy the folder or folders (wildcards cannot be used)
必要参数。指明文件夹复制的具体位置(不可以使用通配符)
overwrite Optional. A Boolean value that indicates whether an existing folder can be overwritten. True allows existing folders to be overwritten and False prevents existing folders from being overwritten. Default is True
可选组件。它是一个逻辑值,用于设定是否拥有覆盖现存文件夹的权限。如果值为“true真”,则可以覆盖现存文件夹;如果是“false假”,则不可以覆盖。默认时为:true真。

Examples
举例

<%
'copy all the folders in c:mydocumentsweb
'to the folder c:webpages
dim fs
set fs=Server.CreateObject("Scripting.FileSystemObject")
fs.CopyFolder "c:mydocumentsweb*","c:webpages"
set fs=nothing
%>
<%
'copy only the folder test from c:mydocumentsweb
'to the folder c:webpages
dim fs
set fs=Server.CreateObject("Scripting.FileSystemObject")
fs.CopyFolder "c:mydocumentswebtest","c:webpages"
set fs=nothing
%>

评论 (0) All

登陆 | 还没注册?