[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 FN_GFSDTIM()
 Get Netware file server date and time
------------------------------------------------------------------------------
 Syntax
 
      fn_gFSdTim() -> { dDate, cTime }
 
 Arguments

     None

 Returns

     A two element array.  The first element is the current file
     server date, and the second element is the current file
     server time.

     If anything goes wrong with the function, you'll simply get
     a null date and an empty string for the time.

 Description

     This call obtains the current file server date and time.

     This function can be used to synchronize workstation
     clocks to the file server time.  This can be used as a
     security measure if some program depends on the current
     time.

 Examples

     /*  Here is a replacement for the Netware utility SYSTIME,
         written in Clipper.  Note that SYSTIME updates the
         current workstation date and time, as well as tells you
         what the default file server's date and time is.
         Requires NANFOR.LIB, of course.
     */

     function systime()
         local aRes

         aRes := fn_gFSdTim()
         if !empty( aRes[1] ) .and. !empty( aRes[2] )
            ft_setdate( aRes[1] )
            ft_settime( aRes[2] )
            qout( cdow(   aRes[1] )      + ", " + ;
                  cMonth( aRes[1] )      + " "  + ;
                  str(  day( aRes[1] ) ) + ", " + ;
                  str( year( aRes[1] ) ) " "  " + ;
                  aRes[2]                         ;
                )
         endif
         return nil




 Source: N:\SRC\FSERV\FSDTIME.PRG

 Author: Glenn Scott

This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson