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

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 DeleteFolder 方法


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

The DeleteFolder method deletes one or more specified folders.
DeleteFolder的作用是删除一个或多个指定的文件夹

Note: An error will occur if you try to delete a folder that does not exist.
注意:如果你试图删除一个不存在的文件夹的话将导致错误产生。

Syntax
语法

FileSystemObject.DeleteFolder(foldername[,force])

Parameter参数 Description描述
foldername Required. The name of the folder or folders to delete (Wildcards are allowed)
必要组件。设定需要被删除的文件夹的名称(可以使用通配符)
force

Optional. A Boolean value that indicates whether read-only folders will be deleted. True indicates that read-only folders will be deleted, False indicates that they will not be deleted. Default is False  
可选组件。它是一个逻辑值,用于设定是否可以删除只读格式(read-only)的文件夹。如果值为“true真”,则可以删除;如果是“false假”,则不可以删除。默认时为:false假。

Example
举例

<%
dim fs
set fs=Server.CreateObject("Scripting.FileSystemObject")
if fs.FolderExists("c:temp") then fs.DeleteFolder("c:temp")
end if
set fs=nothing
%>

评论 (0) All

登陆 | 还没注册?