CT_ShowTime

ShowTime()
 Continuously displays the time at desired screen position

 Syntax

     ShowTime([<nRow>], [<nColumn>], [<lMode>],
        [<cAttr|nAttr>], [<l12/24>], [<lAM/PM>]) --> cNull

 Arguments

     <nRow>  Designates the row where the time is displayed.  The default
     is the cursor row.

     <nColumn>  Designates the column where the time is displayed.  The
     default is the cursor column.

     <lMode>  Designates whether seconds are to appear in the time
     display (.F.), or not (.T.).  The default is display seconds (.F.).

     <cAttr|nAttr>  Designates to the screen attribute to use for the
     time display.  Strings in the form "NN/NN" or "CC/CC" (e.g., "0/7" or
     "B/GR") are possible.  The default is the setting for CLEARA (see
     Introduction, Video Functions).

     <l12/24>  By designating this parameter as .T., a 12-hour display is
     selected.  The default is a 24-hour display (.F.).

     <lAM/PM>  If you have a 24-hour display, you may want to switch on
     an am/pm display.  When you specify this parameter as .T., an "a" or "p"
     (as in DOS), appears to reflect the time.  The default is no display
     (.F.).

     ()  A call without parameters uninstalls the time display.

 Returns

     ShowTime() always returns a null string.

 Description

     This function permits you to constantly display the time in any screen
     position desired. ShowTime() is interrupt controlled and has the ability
     to display the time in either "hh:mm:ss" or "hh:mm" format.  A 12- or 24     -hour display can be selected, with or without an am/pm display.

 Notes

     Warning!  ShowTime() works with the interrupt system.  Before
     leaving your Clipper application, you must uninstall ShowTime() , so
     that the interrupt vectors can be restored.  Otherwise, the system will
     be unstable and will eventually crash.  Simultaneous use of the
     accompanying Extended Drivers Modules automatically restores the
     interrupt vectors in use.

     .  Specify the screen attribute as either a numeric or a string
        in "NN/NN" form.  If no attribute is specified, the value for CLEARA
        applies (see Introduction Video Functions).

 Examples

     .  Display a clock in row 0, column 70, with no seconds display
        and the standard attribute.  When a display is shown in row 0, switch
        SCOREBOARD off!

        SET SCOREBOARD OFF
        ShowTime(0, 70, .T.)      //  Turn on clock
           *...
           *...
        SHOWTIME()                //  Uninstall clock

     .  Show a 12-hour display with am/pm on the lowest row.  White
        letters on a blue background:

        ShowTime(24, 70, .T., "W/B")
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s