CompositeActivity.Dispose(Boolean) Method

Definition

Calls Dispose(Boolean) on this instance, and optionally calls Dispose() on all child activities of this instance.

protected override void Dispose(bool disposing);

Parameters

disposing
Boolean

true to release both managed and unmanaged resources used by this instance and all child activities of this instance; false to release only the unmanaged resources of this instance.

Remarks

Throughout an activity's lifetime, several .NET objects may be created or disposed. Every time a workflow instance is unloaded from memory, the .NET objects corresponding to the activities in the workflow tree are disposed (the Dispose method is called on each activity). When the workflow instance is loaded back into memory, a new .NET object is created for each activity with the state from the corresponding unload.

Applies to

Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1