ASP GetParentFolderName方法
GetParentFolderName方法は、名前の最後の構成要素の親フォルダ内の指定されたパスを返します。
文法
FileSystemObject.GetParentFolderName(path)
参数 | 描述 |
---|---|
path | 必需的。需返回其父文件夹名称的文件或文件夹的路径。 |
例
<%
dim fs,p
set fs=Server.CreateObject("Scripting.FileSystemObject")
p=fs.GetParentFolderName("c:\winnt\cursors\3dgarro.cur")
Response.Write(p)
set fs=nothing
%>
输出:
c:\winnt\cursors
dim fs,p
set fs=Server.CreateObject("Scripting.FileSystemObject")
p=fs.GetParentFolderName("c:\winnt\cursors\3dgarro.cur")
Response.Write(p)
set fs=nothing
%>
输出:
c:\winnt\cursors
完全なファイルシステムオブジェクトのオブジェクト参照