Home Search

DriveWorks Pro 24
PDMPro: Delete Folder

Send Feedback

PDMPro: Delete Folder

This Specification Flow Task will delete a folder from inside the vault.

The folder must be empty, otherwise the task will fail.

Please see the following articles to ensure the DriveWorks plugin and SOLIDWORKS PDM are set up correctly.

Properties

Property NameDescription
Source Folder PathPath of the folder to delete (must be inside vault).
Delete folder contentDelete folder content including all subfolders and files.
Constant NameThe name of the Constant into which the result should be driven (Optional).

Example

When this task is added, the properties are static by default.
See How To: Change A Static Property To A Dynamic Property to enable rules to be built on these properties.

Deleting a folder and reporting the state of the Task in a DriveWorks Constant.

The folder to delete is called FolderToDelete and is located under C:\VaultName\VaultFolder.

The Constant used for reporting is called DeleteFolderFromVaultResult.

PropertyExample ruleExample resultMeaning
Source File NameDWVariableVaultLocation & FolderToDeleteReturnIf the variable VaultLocation equals "C:\VaultName\VaultFolder\" and the FolderToDelete control value equals "FolderToDelete", the path would be evaluated to "C:\VaultName\VaultFolder\FolderToDelete".DriveWorks will delete the vault folder "C:\VaultName\VaultFolder\FolderToDelete".
Constant NameDWConstantDeleteFolderFromVaultResultSuccessfully deleted the folder 'C:\VaultName\VaultFolder\FolderToDelete'DriveWorks will put the result of the Task in the Constant called DeleteFolderFromVaultResult.

Using the Task in a Specification Macro

This task has different types of Outputs. For more information about Outputs see Specification Macros Task Node.

Outputs are only available within Specification Macros.

Outputs

  • Files Deleted

    A table containing a list of files that were deleted.
  • Files Not Deleted

    A table containing a list of files that could NOT be deleted, with reasons.

Status Outputs

This task supports Status Outputs. They can be used to perform different actions depending on what the status outcome of the task is. For more information see Status Outputs in the Task Node Outputs section of Specification Macros Task Node.

The status output navigation is as follows:

Success

  • Successfully deleted the folder and its content.

Success with Warnings

  • Constant of the name <Name> does not exist.

Failure (one of the following occurred)

  • Couldn’t connect to the vault.
  • Delete folder content was expecting a Boolean but found <Value> folder not deleted.
  • Folder not in vault.
  • Couldn’t delete folder.