Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- The Guide To Clipper - <b>recsize()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
RECSIZE()


Syntax:     RECSIZE()

Purpose:    To determine the record length of the current database file.

Returns:    An integer numeric value.

            RECSIZE() returns the record length for the database file in
            USE in the current work area.  If no database file is in
            USE, RECSIZE() returns zero.

Usage:      RECSIZE() determines the length of a record by taking the
            length of each field in the record and adding one character
            to the total (for the asterisk that indicates a deleted
            record).  When this value is multiplied by LASTREC(), the
            product is the amount of space occupied by the file's
            records.

            RECSIZE() is useful in programs that perform automatic file
            backup.  When used in conjunction with DISKSPACE(), the
            RECSIZE() function can assist in ensuring that sufficient
            free space exists on a disk before a file is stored.

Library:    EXTEND.LIB


----------------------------------- Example --------------------------------

   The following user-defined function uses RECSIZE() to calculate the
   length of the current database file:

   FUNCTION FileSize

   RETURN (RECSIZE() * LASTREC()) + HEADER()


See Also: DISKSPACE() FIELD() HEADER() LASTREC()

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