Hello,
We use SUF 9 to install content on client workstations. When we install new content we like to delete all the old content before installing the new content. this content consists of numerous folders of documents.
Currently we are using Folder.Delete to delete each folder individually - like this:
Folder.DeleteTree("C:\\Program Files\\CaseWare\\Document Library\\MP General Doc Library 6.0", nil);
While this method works well I currently have to list out 44 folder delete commands. The number and name of the folders are changing on a regular basis with the exception of the MP at the front of the folder name.
We are trying to determine how to delete all folders in a directory that start with MP in the folder name without affecting any other folders in that directory.
We are currently using the following code to try and accomplish this but it is not working. Does anyone have a suggestion on how to accomplish this?
tbl_folders = Folder.Find("C:\\Program Files\\Test\\", "MP*", false, nil);
for index in tbl_folders do
Folder.DeleteTree(tbl_folders[index], nil);
end
Thanks
We use SUF 9 to install content on client workstations. When we install new content we like to delete all the old content before installing the new content. this content consists of numerous folders of documents.
Currently we are using Folder.Delete to delete each folder individually - like this:
Folder.DeleteTree("C:\\Program Files\\CaseWare\\Document Library\\MP General Doc Library 6.0", nil);
While this method works well I currently have to list out 44 folder delete commands. The number and name of the folders are changing on a regular basis with the exception of the MP at the front of the folder name.
We are trying to determine how to delete all folders in a directory that start with MP in the folder name without affecting any other folders in that directory.
We are currently using the following code to try and accomplish this but it is not working. Does anyone have a suggestion on how to accomplish this?
tbl_folders = Folder.Find("C:\\Program Files\\Test\\", "MP*", false, nil);
for index in tbl_folders do
Folder.DeleteTree(tbl_folders[index], nil);
end
Thanks