Tools — Date/Time Functions

Introduction Date/Time Functions
ADDMONTH()   Adds or subtracts months to/from a date
BOM()        Determines the date of the first day of a month
BOQ()        Determines the date for the beginning of a quarter
BOY()        Determines the date for the beginning of a year
CTODOW()     Converts the day of the week name into a corresponding number
CTOMONTH()   Converts the name of the month into a corresponding number
DMY()        Returns a date in "DD Month YY" format
DOY()        Determines the day of the year for a specific date
EOM()        Determines the date for the last day of a month
EOQ()        Determines the date for the end of a quarter
EOY()        Determines the date for the end of the year
ISLEAP()     Tests if a specific year is a leap year
LASTDAYOM()  Determines the number of days in a month
MDY()        Returns a date in the "Month DD, YY" format
NTOCDOW()    Changes the number of a weekday into a weekday name
NTOCMONTH()  Changes the number of a month into a month name
QUARTER()    Determines the quarter in which a specific date lies
SECTOTIME()  Converts seconds into a time string
SETDATE()    Sets the system date
SETTIME()    Sets the system clock
SHOWTIME()   Continuously displays the time at desired screen position
STOD()       Converts an ANSI date string into Clipper format
TIMETOSEC()  Calculates the seconds since midnight
TIMEVALID()  Determines whether a specified time is valid
WAITPERIOD() Pauses a specified time in increments of 1/100 seconds
WEEK()       Returns the calendar week for a date
WOM()        Returns the week within a month.

Tools — Printer Functions

Introduction Printer Functions
NUMPRINTER() Returns the number of parallel ports
PRINTFILE()  Prints out ASCII files; clears high bits
PRINTINIT()  Initializes one of the printers
PRINTREADY() Determines if a particular printer is ready
PRINTSCR()   Prints screen contents
PRINTSCRX()  Prints screen contents while it exchanges specific characters
PRINTSEND()  Sends characters directly to a printer
PRINTSTAT()  Determines the status of a parallel port
SPOOLACTIV() Determines if the DOS PRINT program is installed
SPOOLADD()   Appends a file to the print queue.
SPOOLCOUNT() Determines the number of entries in the print spool queue
SPOOLDEL()   Deletes files from the print queue
SPOOLENTRY() Determines the name and path of a print job
SPOOLFLUSH() Completely empty the print queue
TOF()        Determines if Clipper is at top of form (TOF)

Tools — Disk Utilities

Introduction Disk Utilities
DELETEFILE() Deletes an error-tolerant file
DIRCHANGE()  Changes the current directory
DIRMAKE()    Creates a directory
DIRNAME()    Determines the name of the current directory
DIRREMOVE()  Removes a directory
DISKCHANGE() Changes the current disk drive
DISKCHECK()  Creates a checksum for a disk
DISKFORMAT() Formats disks, controlled through a UDF
DISKFREE()   Determines the space available on a floppy or hard disk
DISKNAME()   Determines the drive designator for the current drive
DISKREADY()  Tests to see if a disk drive is ready
DISKREADYW() Queries whether you can write to a drive
DISKSPEED()  Determines a comparison value for the drive speed
DISKSTAT()   Determines the status of a drive.
DISKTOTAL()  Determines the total capacity of a floppy or hard disk
DISKTYPE()   Determines the type of data carrier
DRIVETYPE()  Determines the drive type
FILEAPPEND() Appends data to a file
FILEATTR()   Determines a file's attributes
FILECCLOSE() Closes a file after backup mode
FILECCONT()  Copies sections of a file in backup mode
FILECDATI()  Determines which date the target file contains with FILECOPY()
FILECHECK()  Calculates/computes/determines a checksum for a file
FILECOPEN()  Tests to see if the file is still open in the backup mode
FILECOPY()   Copies files normally or in backup mode
FILEDATE()   Determines the file date
FILEDELETE() Deletes file(s) by name and attribute
FILEMOVE()   Moves files to another directory
FILESEEK()   Searches for files by name and attribute
FILESIZE()   Determines the size of a file
FILESTR()    Reads a portion of a file into a string
FILETIME()   Determines a file's time
FILEVALID()  Tests whether a string has a valid file name
FLOPPYTYPE() Determines the exact type of floppy drive
GETSHARE()   Determines the file open (share) mode
NUMDISKF()   Determines the number of installed disk drives
NUMDISKH()   Determines the number of hard disks
NUMDISKL()   Determines the number of available logical drives
RENAMEFILE() Fault tolerant renaming of a file.
RESTFSEEK()  Restores the FILESEEK environment
SAVEFSEEK()  Saves the current FILESEEK environment
SETFATTR()   Sets a file's attributes
SETFCREATE() Default attribute for creating with CA-Clipper Tools functions
SETFDATI()   Sets the date and time of a file
SETSHARE()   Sets default opening mode for CA-Clipper Tools file functions
STRFILE()    Writes a string to a file
TEMPFILE()   Creates a file for temporary use
TRUENAME()   Standardizes the path designation
VOLSERIAL()  Determines the DOS disk serial number
VOLUME()     Establishes a volume label for a floppy or hard disk

Tools – Video Functions

Introduction Video Functions
CHARPIX()    Returns the number of pixel lines per character
CHARWIN()    Exchanges particular characters in a screen area.
CLEAREOL()   Clears from the cursor position to the end of line
CLEARSLOW()  Deletes a screen area from the outside in with a delay
CLEARWIN()   Clears a screen area
CLEOL()      Clears characters and attributes to the end of a line
CLWIN()      Clears character and attribute from a screen area
COLORREPL()  Exchanges particular screen attributes
COLORTON()   Converts NN/NN or CC/CC color values into numeric values
COLORWIN()   Exchanges particular attributes in a screen area
EGAPALETTE() Changes EGA palette colors
ENHANCED()   Selects the enhanced color value for SET COLOR TO output
FILESCREEN() Reads screen content from a file
FONTLOAD()   Loads EGA/VGA fonts from another file
FONTRESET()  Resets all font and palette changes to the ROM defaults
FONTROTATE() Rotates and mirrors images within a font string
FONTSELECT() Determines font areas for normal- and high-intensity output
GETCLEARA()  Queries the current attribute for the clearing functions
GETCLEARB()  Queries the default character for the clearing functions
GETFONT()    Queries the current font
GETSCRSTR()  Queries screen output that was redirected by SETSCRSTR()
GETVGAPAL()  Determines the palette settings on a VGA card
INVERTATTR() Inverts the foreground and background of an attribute
INVERTWIN()  Inverts all attributes in an area of the screen
ISCGA()      Tests for presence of a CGA card or if one can be emulated
ISEGA()      Determines if an EGA card is present or can be emulated
ISHERCULES() Determines if a HERCULES card is present or can be emulated
ISMCGA()     Determines if an MCGA card is present or can be emulated
ISMONO()     Determines if a monochrome card is present or can be emulated
ISPGA()      Determines if a PGA card is present or can be emulated
ISVGA()      Determines if a VGA card is present
MAXFONT()    Determines the number of available fonts
MONISWITCH() Switches between monochrome and color screen
NTOCOLOR()   Converts a numeric value into a color value
NUMCOL()     Restores the number of available screen columns
RESTCURSOR() Restores a saved cursor position and form
SAVECURSOR() Saves current cursor position and form
SAYDOWN()    Displays screen output downward and vertically
SAYMOVEIN()  Displays screen output with a "move in" effect
SAYSCREEN()  Output to the screen without changing the attribute
SAYSPREAD()  Displays screen output with "spread" effect
SCREENATTR() Determines the attribute at a particular position
SCREENFILE() Writes screen content to a file
SCREENMARK() Searches for a string and marks it with an attribute
SCREENMIX()  Mixes characters and attributes of a screen
SCREENSIZE() Queries the number of characters that can be displayed
SCREENSTR()  Reads a string, including attributes, from the screen
SETCLEARA()  Changes the default attribute for screen clear
SETCLEARB()  Changes the default character for screen clear
SETFONT()    Loads the font directly out of a string
SETRC()      Sets line and column for the CA-Clipper cursor
SETSCRSTR()  Redirects screen output into a string
STANDARD()   Selects the standard color value for SET COLOR TO output
STRSCREEN()  Displays a string with characters and attributes on the screen
UNSELECTED() Selects the unselected color value for SET COLOR TO output
UNTEXTWIN()  Replaces an area of characters from a region of the screen
VGAPALETTE() Changes VGA palette colors
VIDEOINIT()  Reinitializes a video system after a RUN
VIDEOSETUP() Queries video mode at system start
VIDEOTYPE()  Returns bit-coded information about available video modes

Tools – Serial Communications

Introduction Serial Communications
COM_BREAK()  Creates a break on a transmission line
COM_CLOSE()  Clears the receiving buffer and closes the com port
COM_COUNT()  Counts the number of characters in the input buffer
COM_CRC()    Computes a Cyclic Redundancy Check (CRC) for the string
COM_CTS()    Queries the Clear To Send (CTS) status
COM_DCD()    Queries the Data Carrier Detect (DCD) status
COM_DOSCON() Provides screen output through DOS--ANSI.SYS terminal emulation
COM_DSR()    Queries the Data Set Ready (DSR) status
COM_DTR()    Queries/sets the Data Terminal Ready (DTR) status
COM_ERRCHR() Defines replacement for a character not received correctly
COM_EVENT()  Designates which event at the port triggered a key trap
COM_FLUSH()  Clears the receiving buffer
COM_GETIO()  Determines the base address of a port
COM_GETIRQ() Determines the interrupt request for a port
COM_HARD()   Turns the hardware handshake (automatic CTS) on/off
COM_INIT()   Initializes the port parameters
COM_KEY()    Monitors the port using key traps
COM_LSR()    Reads the Line Status Register (LSR)
COM_MCR()    Reads or sets the Modem Control Register (MCR)
COM_MSR()    Reads the Modem Status Register (MSR)
COM_NUM()    Gives the number of the highest available serial interface port
COM_OPEN()   Opens the port and initializes the buffer
COM_READ()   Reads characters from the receiving buffer
COM_REMOTE() Determines the clear character for the receiving buffer
COM_RING()   Queries the ring line
COM_RTS()    Queries or sets the Request To Send (RTS)
COM_SCOUNT() Counts number of characters in the background sending buffer
COM_SEND()   Transmits data directly or in the background
COM_SETIO()  Changes the base address for a port
COM_SETIRQ() Changes the interrupt request for a port
COM_SFLUSH() Deletes the sending background buffer
COM_SKEY()   Monitors port using key traps during background transmission
COM_SMODE()  Determines the current status of a background transmission
COM_SOFT()   Queries or sets the software handshake (automatic XON/XOFF)
COM_SOFT_R() Tests to see if an XOFF character has been received
COM_SOFT_S() Tests to see if buffer has automatically sent an XOFF character
XMOBLOCK()   Generates a block for XMODEM transmission
XMOCHECK()   Tests a received XMODEM block
ZEROINSERT() Inserts a 0-bit after every fifth 1-bit
ZEROREMOVE() Removes 0-bits in a file block

Tools – Extended Drivers

Introduction Extended Drivers
CGA40()      Switches to 40-column mode (color or monochrome)
CGA80()      Switches to 80-column mode (color or monochrome)
DSETKBIOS()  Turns the extended keyboard mode on or off through BIOS
DSETNOLINE() Ignores the next line feed sent to the screen
DSETQFILE()  Creates a protocol file when the program ends normally
DSETTYPE()   Determines the size of the keyboard buffer (SET TYPEAHEAD TO)
DSETWINDEB() This function is no longer supported
DSETWINDOW() Reroutes external functions and programs to a window
EGA43()      Switches to the 43-line EGA mode
FIRSTCOL()   Sets the first visible column of a virtual screen
FIRSTROW()   Sets the first visible line of a virtual screen
GETBOXGROW() Gets the time delay with which boxes are opened
GETCURSOR()* Determines the setting for the cursor form
GETKXLAT()   Determines the current key code table
GETKXTAB()   Retrieves the entire key code table
GETLINES()   Determines number of lines after which screen display pauses
GETMODE()    Uses the current screen mode as a function name
GETPAGE()    Determines the current screen page
GETPBIOS()   Determines if printing is through DOS or the BIOS
GETPXLAT()   Retrieves the current printer table
GETSCRMODE() Determines the number of the active video mode
GETTAB()     Retrieves tab values for CA-Clipper screen output
INKEYTRAP()  Behaves like INKEY() with support for key traps
INPUTMODE()  Determines previously active or currently active input mode
KEYREAD()    Reads already processed CA-Clipper keyboard buffer input
KEYSEND()    Simulates Clipper keyboard buffer input
MAXCOL()     Extends the Clipper MAXCOL() function
MAXPAGE()    Determines the number of available screen pages
MAXROW()     Extends the Clipper MAXROW() function
MONOCHROME() Switches to the monochrome mode
PAGECOPY()   Copies one screen page to another
PRINTERROR() Returns the error code for the last printer output
SETBELL()    Sets the tone frequency and duration for CHR(7)
SETBOXGROW() Opens boxes with a time delay
SETCURSOR()  Sets the cursor form
SETKXLAT()   Redefines key codes or lock keys
SETKXTAB()   Installs key tables
SETLINES()   Determines number of lines after which screen display pauses
SETMAXCOL()  Sets the number of columns for a virtual screen
SETMAXROW()  Sets the number of lines for a virtual screen
SETPAGE()    Selects a new screen page
SETPBIOS()   Redirects print output to BIOS or DOS, and establishes timeout
SETPXLAT()   Establishes translation tables for printer output
SETQNAME()   Changes the file and path name for the QUIT file
SETSCRMODE() Establishes a new video mode
SETTAB()     Sets the tab widths for CA-Clipper screen outputs
TRAPANYKEY() Calls a procedure with any keyboard input
TRAPINPUT()  Allows supervision of CA-Clipper input commands
TRAPSHIFT()  Calls a procedure that depends on switching keys
VGA28()      Switches to 28-line VGA mode
VGA50()      Switches to 50-line VGA mode.

Tools – Window Functions

Introduction Window Functions
WACLOSE()    Closes all windows
WBOARD()     Allocates allowable screen area for windows
WBOX()       Places a frame around the active window
WCENTER()    Returns a window to the visible screen area, or centers it
WCLOSE()     Closes the active window
WCOL()       Returns position of the leftmost column of the active window
WFCOL()      Returns position of leftmost column of formatted area of window
WFLASTCOL()  Returns position of rightmost col of formatted area of a window
WFLASTROW()  Returns position of bottom row of formatted area of a window
WFORMAT()    Determines the usable area within a window
WFROW()      Returns position of top row of the formatted area of a window
WLASTCOL()   Returns position of the rightmost column of the active window
WLASTROW()   Returns the position of the bottom row of the active window
WMODE()      Turns the screen border overstep mode on or off
WMOVE()      Moves a window
WNUM()       Determines the highest window handle
WOPEN()      Opens a new window
WROW()       Returns the position of the top row of the active window
WSELECT()    Activates one of the open windows
WSETMOVE()   Turns the interactive movement mode on or off
WSETSHADOW() Sets the window shadow colors
WSTEP()      Determines the step width of interactive window movement