다음을 통해 공유


ActivityBind 생성자

정의

ActivityBind 클래스의 새 인스턴스를 초기화합니다.

오버로드

ActivityBind()

ActivityBind 클래스의 새 인스턴스를 초기화합니다.

ActivityBind(String)

ActivityBind 매개 변수를 사용하여 name 클래스의 새 인스턴스를 초기화합니다.

ActivityBind(String, String)

ActivityBindname 매개 변수를 사용하여 path 클래스의 새 인스턴스를 초기화합니다.

ActivityBind()

ActivityBind 클래스의 새 인스턴스를 초기화합니다.

public:
 ActivityBind();
public ActivityBind ();
Public Sub New ()

예제

이 예제에서는 ActivityBind를 만들고 사용하는 방법을 보여 줍니다.

이 코드 예제는 ThrowActivity.cs 파일에 있는 Throw Activity SDK 샘플의 일부입니다. 자세한 내용은 ThrowActivity 활동을 사용 하 여입니다.

public sealed partial class ThrowWorkflow : SequentialWorkflowActivity
{
    [System.Diagnostics.DebuggerNonUserCode()]
    private void InitializeComponent()
    {
        this.CanModifyActivities = true;
        System.Workflow.ComponentModel.ActivityBind activitybind1 = new System.Workflow.ComponentModel.ActivityBind();
        this.throwActivity1 = new System.Workflow.ComponentModel.ThrowActivity();
        activitybind1.Name = "ThrowWorkflow";
        activitybind1.Path = "ThrownException";
        //
        // throwActivity1
        //
        this.throwActivity1.Name = "throwActivity1";
        this.throwActivity1.SetBinding(System.Workflow.ComponentModel.ThrowActivity.FaultProperty, ((System.Workflow.ComponentModel.ActivityBind)(activitybind1)));
        //
        // ThrowWorkflow
        //
        this.Activities.Add(this.throwActivity1);
        this.Name = "ThrowWorkflow";
        this.CanModifyActivities = false;
    }

    private Exception thrownExceptionValue = new System.Exception("My Exception Message.");

    public Exception ThrownException
    {
        get { return thrownExceptionValue; }
        set { thrownExceptionValue = value; }
    }

    private ThrowActivity throwActivity1;
}
Partial Public NotInheritable Class ThrowWorkflow
    Inherits SequentialWorkflowActivity

    <System.Diagnostics.DebuggerNonUserCode()> _
                                        Private Sub InitializeComponent()

        Me.CanModifyActivities = True
        Dim activitybind1 As New System.Workflow.ComponentModel.ActivityBind()
        Me.throwActivity1 = New System.Workflow.ComponentModel.ThrowActivity()
        activitybind1.Name = "ThrowWorkflow"
        activitybind1.Path = "ThrownException"
        ' 
        ' throwActivity1
        ' 
        Me.throwActivity1.Name = "throwActivity1"
        Me.throwActivity1.SetBinding(System.Workflow.ComponentModel.ThrowActivity.FaultProperty, activitybind1)
        ' 
        ' ThrowWorkflow
        ' 
        Me.Activities.Add(Me.throwActivity1)
        Me.Name = "ThrowWorkflow"
        Me.CanModifyActivities = False

    End Sub

    Private thrownExceptionValue As New System.Exception("My Exception Message.")

    Public Property ThrownException() As Exception
        Get
            Return thrownExceptionValue
        End Get
        Set(ByVal value As Exception)
            thrownExceptionValue = value
        End Set
    End Property

    Private throwActivity1 As ThrowActivity

End Class

적용 대상

ActivityBind(String)

ActivityBind 매개 변수를 사용하여 name 클래스의 새 인스턴스를 초기화합니다.

public:
 ActivityBind(System::String ^ name);
public ActivityBind (string name);
new System.Workflow.ComponentModel.ActivityBind : string -> System.Workflow.ComponentModel.ActivityBind
Public Sub New (name As String)

매개 변수

name
String

Activity의 이름입니다.

적용 대상

ActivityBind(String, String)

ActivityBindname 매개 변수를 사용하여 path 클래스의 새 인스턴스를 초기화합니다.

public:
 ActivityBind(System::String ^ name, System::String ^ path);
public ActivityBind (string name, string path);
new System.Workflow.ComponentModel.ActivityBind : string * string -> System.Workflow.ComponentModel.ActivityBind
Public Sub New (name As String, path As String)

매개 변수

name
String

Activity의 이름입니다.

path
String

ActivityBind의 경로입니다.

예제

이 예제에서는 ActivityBind를 만들고 사용하는 방법을 보여 줍니다.

이 코드 예제는 ThrowActivity.cs 파일에 있는 Throw Activity SDK 샘플의 일부입니다. 자세한 내용은 ThrowActivity 활동을 사용 하 여입니다.

public sealed partial class ThrowWorkflow : SequentialWorkflowActivity
{
    [System.Diagnostics.DebuggerNonUserCode()]
    private void InitializeComponent()
    {
        this.CanModifyActivities = true;
        System.Workflow.ComponentModel.ActivityBind activitybind1 = new System.Workflow.ComponentModel.ActivityBind();
        this.throwActivity1 = new System.Workflow.ComponentModel.ThrowActivity();
        activitybind1.Name = "ThrowWorkflow";
        activitybind1.Path = "ThrownException";
        //
        // throwActivity1
        //
        this.throwActivity1.Name = "throwActivity1";
        this.throwActivity1.SetBinding(System.Workflow.ComponentModel.ThrowActivity.FaultProperty, ((System.Workflow.ComponentModel.ActivityBind)(activitybind1)));
        //
        // ThrowWorkflow
        //
        this.Activities.Add(this.throwActivity1);
        this.Name = "ThrowWorkflow";
        this.CanModifyActivities = false;
    }

    private Exception thrownExceptionValue = new System.Exception("My Exception Message.");

    public Exception ThrownException
    {
        get { return thrownExceptionValue; }
        set { thrownExceptionValue = value; }
    }

    private ThrowActivity throwActivity1;
}
Partial Public NotInheritable Class ThrowWorkflow
    Inherits SequentialWorkflowActivity

    <System.Diagnostics.DebuggerNonUserCode()> _
                                        Private Sub InitializeComponent()

        Me.CanModifyActivities = True
        Dim activitybind1 As New System.Workflow.ComponentModel.ActivityBind()
        Me.throwActivity1 = New System.Workflow.ComponentModel.ThrowActivity()
        activitybind1.Name = "ThrowWorkflow"
        activitybind1.Path = "ThrownException"
        ' 
        ' throwActivity1
        ' 
        Me.throwActivity1.Name = "throwActivity1"
        Me.throwActivity1.SetBinding(System.Workflow.ComponentModel.ThrowActivity.FaultProperty, activitybind1)
        ' 
        ' ThrowWorkflow
        ' 
        Me.Activities.Add(Me.throwActivity1)
        Me.Name = "ThrowWorkflow"
        Me.CanModifyActivities = False

    End Sub

    Private thrownExceptionValue As New System.Exception("My Exception Message.")

    Public Property ThrownException() As Exception
        Get
            Return thrownExceptionValue
        End Get
        Set(ByVal value As Exception)
            thrownExceptionValue = value
        End Set
    End Property

    Private throwActivity1 As ThrowActivity

End Class

적용 대상