SqlCeChangeTracking Constructor (SqlCeTransaction)
Initializes a new instance of the SqlCeChangeTracking class with a SqlCeTransaction.
Namespace: System.Data.SqlServerCe
Assembly: System.Data.SqlServerCe (in System.Data.SqlServerCe.dll)
Syntax
'Declaration
Public Sub New ( _
transaction As SqlCeTransaction _
)
'Usage
Dim transaction As SqlCeTransaction
Dim instance As New SqlCeChangeTracking(transaction)
public SqlCeChangeTracking(
SqlCeTransaction transaction
)
public:
SqlCeChangeTracking(
SqlCeTransaction^ transaction
)
new :
transaction:SqlCeTransaction -> SqlCeChangeTracking
public function SqlCeChangeTracking(
transaction : SqlCeTransaction
)
Parameters
- transaction
Type: System.Data.SqlServerCe. . :: . .SqlCeTransaction
A SqlCeTransaction that represents the transaction in which change tracking executes.
Exceptions
Exception | Condition |
---|---|
ArgumentException | The transaction does not have a connection associated with it. |
ArgumentNullException | transaction is null Nothing nullptr unit a null reference (Nothing in Visual Basic) . |
InvalidOperationException | The connection associated with the transaction is not open. -or- The transaction has been disposed. |
Remarks
Creates a tracking object for the specified transaction. The transaction must have a SqlCeConnection associated with it before the constructor is called.