Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- CA-Clipper Tools . Books 1-3 - <b>diskready()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 DISKREADY()
 Tests to see if a disk drive is ready
------------------------------------------------------------------------------
 Syntax

     DISKREADY([<cDrive>], [<lDOS/BIOS>]) --> lDiskReady

 Arguments

     <cDrive>  Designates the drive designator (A, B, C, etc.) of the
     drive to test.  The default is the current disk drive.

     <lDOS/BIOS>  This logical parameter allows you to designate whether
     you want the function tested through the BIOS (.F.) or DOS (.T.).  The
     default is discussed in the Description below.

 Returns

     DISKREADY() returns .T. when the drive being tested is ready to use.

 Description

     To save space, you must frequently make multiple disk copies.
     DISKREADY() allows you to wait for a user disk change, without having to
     confront known DOS errors, or use CA-Clipper error trap functions.  Be
     sure to differentiate between floppy tests and "true" hard disks and
     logical partitions.

 DOS or BIOS

     In the simplest case, this function tests the respective drive through
     DOS.  If drive B is unavailable, the message  "Please insert disk in
     drive B:..." is output from the operating system.  When you test floppy
     drives, drive A: and B:, the BIOS route is recommended, since no message
     is output.  In any event, A: and/or B: can be mapped drives within a
     network.  Use the following logical expression for all the previous
     situations:

     (NETDISK(<cDrive>) .OR. <cDrive> >= "C")

     This logical expression returns .T. when the respective drive is either
     on the network or has a drive identifier of C: or higher.

 Examples

     The system waits between individual copy procedures until drive A: is
     ready again:

     DO Copy                        // Call copy procedure
     ? "Please insert a disk in Drive A:!"
     DO WHILE .NOT. DISKREADY("A")
        *...
     ENDDO
     DO Copy                        // Call copy procedure


See Also: DISKREADYW()

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