TransactionEventArgs 類別

定義

提供下列交易事件的資料:DistributedTransactionStartedTransactionCompleted

public ref class TransactionEventArgs : EventArgs
public class TransactionEventArgs : EventArgs
type TransactionEventArgs = class
    inherit EventArgs
Public Class TransactionEventArgs
Inherits EventArgs
繼承
TransactionEventArgs

範例

下列範例示範如何使用此類型。

//Transaction completed event handler
static void Current_TransactionCompleted(object sender, TransactionEventArgs e)
{

   Console.WriteLine("A transaction has completed:");
   Console.WriteLine("ID:{0}",   e.Transaction.TransactionInformation.LocalIdentifier);
   Console.WriteLine("Distributed ID: {0}", e.Transaction.TransactionInformation.DistributedIdentifier);
   Console.WriteLine("Status:         {0}", e.Transaction.TransactionInformation.Status);
   Console.WriteLine("IsolationLevel: {0}", e.Transaction.IsolationLevel);
}

建構函式

TransactionEventArgs()

初始化 TransactionEventArgs 類別的新執行個體。

屬性

Transaction

取得為其提供事件狀態的交易。

方法

Equals(Object)

判斷指定的物件是否等於目前的物件。

(繼承來源 Object)
GetHashCode()

做為預設雜湊函式。

(繼承來源 Object)
GetType()

取得目前執行個體的 Type

(繼承來源 Object)
MemberwiseClone()

建立目前 Object 的淺層複製。

(繼承來源 Object)
ToString()

傳回代表目前物件的字串。

(繼承來源 Object)

適用於