home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Database / CLIPR503.W96 / TSTRING.PR_ / TSTRING.PR
Text File  |  1995-06-20  |  556b  |  27 lines

  1. /***
  2. *
  3. *  Tstring.prg
  4. *
  5. *  Summer '87 TSTRING() Compatibility Routine
  6. *
  7. *  Copyright (c) 1993, Computer Associates International Inc.
  8. *  All rights reserved.
  9. *
  10. */
  11.  
  12.  
  13. /***
  14. *
  15. *    TSTRING( <seconds> )
  16. *
  17. *    Return a 24-hour time string from numeric seconds
  18. *
  19. *    Note: Time quantities over 24 hours are returned by the DAYS() function.
  20. *
  21. */
  22. FUNCTION TSTRING(cl_secs)
  23.     RETURN STRZERO( INT(MOD(cl_secs/3600, 24)), 2, 0 ) +':'+;
  24.           STRZERO( INT(MOD(cl_secs/  60, 60)), 2, 0 ) +':'+;
  25.           STRZERO( INT(MOD(cl_secs   , 60)), 2, 0 )
  26.  
  27.