ActivityValidationServices::Validate Method (Activity)
Verifies that a workflow activity is correctly configured according to the validation logic. This logic can be the CacheMetadata(CodeActivityMetadata) method of the activities to validate, or build and policy constraints.
Assembly: System.Activities (in System.Activities.dll)
Parameters
- toValidate
- Type: System.Activities::Activity
An element from a workflow activity tree.
Return Value
Type: System.Activities.Validation::ValidationResultsA collection of validation errors, each of which can contain the name of the validated activity, a descriptive message, an error code, and other information.
Custom activity authors can provide validation logic in an activity's CacheMetadata(CodeActivityMetadata) override. Any exceptions that are thrown from CacheMetadata(CodeActivityMetadata) are not treated as validation errors. These exceptions will escape from the call to Validate and must be handled by the caller.
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.