示例:获取根文件夹下的所有文件夹
本示例用于打印标签数据库中根文件夹下所有文件夹的名称。
Sub ShowSubFolders() Dim oFolders As Folders Dim oFolder As Folder 'Get the folders in the Root folder. Set oFolders = TagDB.RootFolder.Folders Debug.Print Debug.Print "The Root folder contains the following sub-folders:" Debug.Print 'Print the name of each folder in the collection. For Each oFolder In oFolders Debug.Print vbTab & oFolder.Name Next oFolder 'Release resources associated with the objects. Set oFolders = Nothing Set oFolder = Nothing End Sub
提供反馈