This documentation is archived and is not being maintained.

Transaction.Current Property

Note: This property is new in the .NET Framework version 2.0.

Gets or sets the ambient transaction.

Namespace: System.Transactions
Assembly: System.Transactions (in system.transactions.dll)

public static Transaction Current { get; set; }
/** @property */
public static Transaction get_Current ()

/** @property */
public static void set_Current (Transaction value)

public static function get Current () : Transaction

public static function set Current (value : Transaction)

Property Value

A Transaction that describes the current transaction.

For more information on ambient transactions, please see the "Transaction Flow Management" section of the Implementing an Implicit Transaction using Transaction Scope topic.

Although you can set the ambient transaction using this property, you should use the TransactionScope object to manipulate the ambient transaction whenever possible.

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.

.NET Framework

Supported in: 2.0