* *
*
* * News
 • Daily news
 • Archived news

Columns
 • WildCard
 • Qbasic Articles
 • QB Comic!

Learning center
 • QB Books
 • Qbasic Lessons!
 • Qbasic FAQ
 • Newbies Section
 • Qbasic Tutorials

* *
*
*
*
*  
.CVI, CVS, CVL, and CVD Functions Details.

  QuickSCREEN      Details      Example      Contents      Index
ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ
CVI, CVS, CVL, and CVD Functions Details
Syntax
  CVI(2-byte-string)
  CVS(4-byte-string)
  CVL(4-byte-string)
  CVD(8-byte-string)
 
CVI, CVS, CVL, and CVD are used with a FIELD statement to read real
numbers from a random-access file. The functions take strings defined
in the FIELD statement and convert them to a value of the corresponding
numeric type. The functions are the inverse of MKI$, MKS$, MKL$, and MKD$:
 
  Function  Description
  CVI       Converts a 2-byte-string created with MKI$ back to an
            an integer.
 
  CVS       Converts a 4-byte-string created with MKS$ back to a
            single-precision number.
 
  CVL       Converts a 4-byte-string created with MKL$ back to a
            long integer.
 
  CVD       Converts an 8-byte-string created with MKD$ back to a
            double-precision number.
 
  Note: The new BASIC record variables provide a more efficient and
        convenient way of reading and writing random-access files.
* * ** * * * *