FaultHandlerActivity.FaultType Property

Definition

Gets or sets the Type of the exceptions to be handled by the FaultHandlerActivity. Exceptions of the type derived from the type specified in FaultType are also handled.

C#
public Type FaultType { get; set; }

Property Value

The Type of the associated Exception.

Examples

The following example shows how to set the FaultType property. This example is from the Compensation SDK sample. For more information, see Compensation Sample.

C#
this.NoProductFault.FaultType = typeof(DiscontinuedProductException);

Remarks

This property must be set to use the FaultHandlerActivity.

Applies to

產品 版本
.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