DdeAbandonTransaction

The DdeAbandonTransaction function abandons the specified asynchronous transaction and releases all resources associated with the transaction.

BOOL DdeAbandonTransaction(
  DWORD idInst,         // instance identifier
  HCONV hConv,          // handle to conversation
  DWORD idTransaction   // transaction identifier
);
 

Parameters

idInst
Specifies the application instance identifier obtained by a previous call to the DdeInitialize function.
hConv
Handle to the conversation in which the transaction was initiated. If this parameter is 0L, all transactions are abandoned (that is, the idTransaction parameter is ignored).
idTransaction
Specifies the identifier of the transaction to abandon. If this parameter is 0L, all active transactions in the specified conversation are abandoned.

Return Values

If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero.

Errors

The DdeGetLastError function can be used to get the error code, which may be one of the following values:

DMLERR_DLL_NOT_INITIALIZED
DMLERR_INVALIDPARAMETER
DMLERR_NO_ERROR
DMLERR_UNFOUND_QUEUE_ID

Remarks

Only a dynamic data exchange (DDE) client application should call DdeAbandonTransaction. If the server application responds to the transaction after the client has called DdeAbandonTransaction, the system discards the transaction results. This function has no effect on synchronous transactions.

QuickInfo

  Windows NT: Requires version 3.1 or later.
  Windows: Requires Windows 95 or later.
  Windows CE: Unsupported.
  Header: Declared in ddeml.h.
  Import Library: Use user32.lib.

See Also

Dynamic Data Exchange Management Library Overview, Dynamic Data Exchange Management Functions, DdeClientTransaction, DdeInitialize, DdeQueryConvInfo