Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Novlib 3.30 Online Reference - <b> ttsbegin()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 TTSBegin()
------------------------------------------------------------------------------
 Purpose:
 Begin a TTS transaction.

 Syntax:
 bResult = TTSBegin()

 Parameters:
 None.

 Returns:
 A boolean value (TRUE or FALSE).

 Description:
 TTSBegin() returns TRUE if the transaction was successfully started.
 Changes made to network files after this function is called are logged
 and only written permanently to the files once the TTSEnd() function
 is called. If the TTSAbort() function is called or the server goes down
 before TTSEnd() is called, all the changes made since the TTSBegin() are
 discarded.

 TTSBegin() returns FALSE if an error occurs, in which case check
 NWErrorGet() for the error code returned.

 The following error codes are for information only, rather than actual
 errors:

    Error Description

    254   An existing implicit transaction has been converted to an
          explicit transaction.
    255   An explicit transaction is already in progress.

 Example:
 // To begin a new transaction:
 if ( !TTSBegin() )
    if ( NWErrorGet() >= 254 )
       ? "Ignored as already in a transaction"
    else
       ? "Error starting transaction"
    endif
 endif

 Notes:
 Note for CA-Clipper / CA-Visual Objects: Read Chapter 13,
 Transaction Tracking Functions before using this function, to understand
 the compatibility issues between xBase file formats and TTS.

See Also: TTSEnd() TTSAbort()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson