Redigera

Dela via


ReceiveActivity.GetWorkflowServiceAttributes(Object) Method

Definition

Returns the WorkflowServiceAttributes attributes for the service implemented by the ReceiveActivity activity. These attributes include items like the AddressFilterMode, the ConfigurationName, the IncludeExceptionDetailInFaults, and whether to include exception details in any faults that are returned from the ReceiveActivity activity.

public:
 static System::Object ^ GetWorkflowServiceAttributes(System::Object ^ dependencyObject);
public static object GetWorkflowServiceAttributes (object dependencyObject);
static member GetWorkflowServiceAttributes : obj -> obj
Public Shared Function GetWorkflowServiceAttributes (dependencyObject As Object) As Object

Parameters

dependencyObject
Object

The object to retrieve the service attributes from.

Returns

A Object that represents a WorkflowServiceAttributes object that contains service attribute data.

Examples

The following example shows how to use the GetWorkflowServiceAttributes method.

WorkflowServiceAttributes serviceAttributes = (WorkflowServiceAttributes)ReceiveActivity.GetWorkflowServiceAttributes(rootActivity);

Remarks

The WorkflowServiceAttributesProperty property is an attached dependency property defined by the ReceiveActivity activity. This dependency property is attached to the root workflow that contains the ReceiveActivity activity using the SetWorkflowServiceAttributes method call at design time.

The WorkflowServiceAttributesProperty property is used for defining service-level behavior attributes that are applied to the workflow service when it starts. These cannot be modified at runtime.

Note

If the current workflow starts another workflow using an InvokeWorkflowActivity activity, the invoked workflow does not inherit the invoking workflow's service attributes.

Note

If service attributes are set for a custom activity and that activity is included in a workflow, those service attributes are used. Service attributes are only used for custom activities if the custom activity itself is run as a workflow.

Applies to