假如指定的文件夾是根文件夾則返回 True ;否則返回 False 。
object.IsRootFolder
object 應為 Folder 對象。
下面的代碼說明了 IsRootFolder 屬性的用法:
function DisplayLevelDepth(pathspec){var fso, f, n, s = "";fso = new ActiveXObject("Scrf = fso.GetFolder(pathspec);n = 0;if (f.IsRootFolder)s = "The specified folder is the root folder."else{do{f = f.ParentFolder;n++;}while (!f.IsRootFolder)s = "The specified folder is nested " + n + " levels deep."}return(s);}
Attributes 屬性 DateCreated 屬性 DateLastaccessed 屬性 DateLastModified 屬性 Drive 屬性 Files 屬性 Name 屬性 ParentFolder 屬性 Path 屬性 ShortName 屬性 ShortPath 屬性 Size 屬性 SubFolders 屬性 Type 屬性
應用于: Folder 對象
新聞熱點
疑難解答