PRODUCT






Home









Free Download








Installation Instructions





FAQ





FAQ








Ask A Question





LEARN SCRIPTING





Overview








Lesson 1








2


3


4


5








Exam





SAMPLE SCRIPTS





Computer








Internet








Administrators








Developers








Data








Miscellaneous





HELP / DOCUMENTATION





Commands








Automated Internet








Automated Editors








Sample Scripts








Precompiled Functions








System Features






  Help Page - gettime

( Some help pages may not display correctly in html because those help pages may have sample code
in them, part of which may be mis-interpreted as html tags.

All help pages, including this help page, are available in biterScripting with the help command. )




Function gettime Purpose Gets current (date and) time. Return Type string Syntax gettime() Arguments None. Return Value A string value representing current time. Stream Input Streams apply to commands and not to functions. Stream Output Streams apply to commands and not to functions. Stream Error Streams apply to commands and not to functions, although any errors will be written here. Description The returned string has 14 characters in the following format. yyyymmddHHMMss yyyy 4 digit year mm 2 digit month, 01 thru 12 dd 2 digit day, 01 thru 31 HH 2 digit hour on 24-hour basis, 00 thru 23 MM 2 digit minute, 00 thru 59 ss 2 digit second, 00 thru 59 chex command can be used to further extract individual components of the returned time. Restrictions Most 32-bit systems will not be able to hold the entire 14-digit time value described above, in an int variable. So to convert the return value from this function into a numeric value, always use real. All system functions are declared as global, and can not be redeclared (overloaded). Valid Examples chex "4]" gettime() Will show the current year. echo "Current year is " { chex "4]" gettime() } Will print the string "Current year is " followed by the current year. Invalid Examples var real rtime set $rtime = gettime() If the intention is to get system time in real type, the above will be incorrect. (It will set $rtime to 1.0, since the gettime() function will return a non-empty str value.) The correct way to do this is as follows. set $rtime = makereal( str( gettime() ) ) var int itime set $itime = makeint( str( gettime() ) ) On 32-bit sytems, the value of $itime will be invalid. Use real data type instead. See Also addtime difftime getdow constant var conversion chex

2008-2013, biterScripting.com. All rights reserved.
biterScripting, biterScript, biterBrowser, biterMobile, biterScripting.com, FVA (Forward Variable Assignment) are trademarks of biterScripting.com. Is it biterScripting-compatible ? is a service mark of biterScripting.com. Explorer, Unix, Windows are trademarks, service marks or other forms of intellectual property of their respective owners.