ClearCollection<T> Activity Designer
Applies to: Visual Studio Visual Studio for Mac Visual Studio Code
The ClearCollection<T> activity designer is used to create and configure a ClearCollection<T> activity.
The ClearCollection<T> Activity
The ClearCollection<T> activity clears a specified collection of all items.
Using the ClearCollection<T> Activity Designer
The ClearCollection<T> activity designer can be found in the Collection category of the Toolbox, which is accessed by clicking the Toolbox tab of the Workflow Designer. Alternatively, select Toolbox from the View menu, or press Ctrl+Alt+X.
The ClearCollection<T> activity designer can be dragged from the Toolbox and dropped on to the Workflow Designer surface wherever activities are placed, such as inside a Sequence. Dropping the activity designer creates a ClearCollection<T> activity with a default DisplayName of ClearCollection<Int32>. (By default, the TypeArgument is Int32. TypeArgument can be changed in the property grid.) The DisplayName value can be edited in the header of the ClearCollection<T> activity designer or in the DisplayName box of the property grid. The other properties must be edited on the property grid.
The ClearCollection<T> Properties
The following table shows the ClearCollection<T> properties and describes how they are used in the designer.
|DisplayName||False||Specifies the optional friendly name of the ClearCollection<T> activity. The default is ClearCollection<Int32>. Although the DisplayName value is not strictly required, it is a best practice to use one.|
|Collection||True||Specifies the collection to be cleared of items. This collection is of type ICollection<TypeArgument>. To specify the collection, type a Visual Basic expression in the property grid.|
|TypeArgument||True||Specifies the type T of the items contained in the ICollection<T>. By default, this TypeArgument type is set to Int32. To change the type, change the value of the TypeArgument in the combo box in the property grid.|