Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

ITransactionDispenser::BeginTransaction

This method initiates a new transaction and returns a new transaction object which represents the transaction.

HRESULT BeginTransaction( 
  IUnknown * punkOuter,  ISOLEVEL isoLevel,  ULONG isoFlags,  ITransactionOptions * pOptions,  ITransaction ** ppTransaction);

punkOuter
[in] Must be NULL.

isoLevel
[in] The isolation level to be used for this transaction, specified by the ISOLATIONLEVEL enumeration. This value is ignored by DTC and passed on to the resource managers.

isoFlags
[in] Values from ISOFLAG enumeration.

pOptions
[in] A pointer to a transaction options object. This value may be NULL. If pOptions is NULL the time-out value for the transaction is infinite and the transaction will not have a description.

ppTransaction
[out] Pointer to the pointer to the ITransaction interface on the new transaction object.

S_OK
Success.

CLASS_E_NOAGGREGATION
punkOuter was not NULL.

XACT_E_LOGFULL
Unable to begin a new transaction because the log file is full.

XACT_E_NOTIMEOUT
A time-out was specified, but time-outs are not supported.

E_OUTOFMEMORY
Unable to allocate memory.

E_FAIL
An unknown error occurred.

E_UNEXPECTED
An unknown error occurred.

E_INVALIDARG
ppTransaction was NULL.

XACT_E_CONNECTION_DOWN
No longer able to communicate with the transaction manager because the connection to the transaction manager failed.

XACT_E_TMNOTAVAILABLE
Unable to connect to the transaction manager or the transaction manager is unavailable.

XACT_E_CONNECTION_DENIED
The transaction manager refused to accept a connection.

A transaction options object which is passed as a parameter to BeginTransaction must not be altered while the BeginTransaction method invocation is outstanding.

For an explanation of the requirement values, see Requirements.

Platforms: Windows 2000, Windows XP, Windows Server 2003

Header: Declared in transact.h

Show:
© 2015 Microsoft