Difference between revisions of "Manuals/calci/TIME"

From ZCubes Wiki
Jump to navigation Jump to search
(Created page with "<div id="6SpaceContent" class="zcontent" align="left"> '''TIME'''(SomeHour, SomeMinute, SomeSecond) where, '''SomeHour''' - a number represents the hour. '''SomeM...")
 
Line 1: Line 1:
<div id="6SpaceContent" class="zcontent" align="left">
+
=TIME(SomeHour, SomeMinute, SomeSecond)=
 
 
'''TIME'''(SomeHour, SomeMinute, SomeSecond)
 
  
 
where,
 
where,
  
'''SomeHour''' - a number represents the hour.
+
<math>SomeHour</math> is a number that represents hour value
  
'''SomeMinute''' - a number representing the minute..
+
<math>SomeMinute</math> is a number that represents minute value
  
'''SomeSecond''' - a number representing the second.
+
<math>SomeSecond</math> is a number that represents seconds value
  
</div>
 
----
 
<div id="1SpaceContent" class="zcontent" align="left">
 
  
Calci returns the today's date and time.
+
TIME() returns the decimal number representing particular time or the time itself.
  
</div>
 
----
 
<div id="7SpaceContent" class="zcontent" align="left">
 
  
Calci use different date systems as their default.
+
== Description ==
  
</div>
+
TIME(SomeHour, SomeMinute, SomeSecond)
----
 
<div id="12SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="left">
 
  
TIME
+
For Example,
  
<font size="6"></font>
+
TIME(2,30,54)
  
</div></div>
+
*In ZOS, time value is returned as ''0.10479166666482342''
----
+
*In Calci, time value is returned as ''2:30:54 AM''
<div id="8SpaceContent" class="zcontent" align="left">
 
  
Lets see an example in (Column1, Row2)
+
*Calci displays the time considering a 24 hour clock from 0:00:00 (12:00:00 AM) to 23:59:59 (11:59:59 PM).
 +
*The decimal output of time value is in the range from '0' to '0.99988426'. e.g. 12:00 PM is half of a day, represented as '0.5' or '0.25'.
 +
*If <math>SomeHour</math> &gt;23, it is divided by 24 and the remainder is considered as hour value. e.g. TIME(30,00,00) = 5 AM.
 +
*If <math>SomeHour</math> is negative, it is subtracted from 23:59:59 and displayed as hour value.
 +
*If <math>SomeMinute</math> &gt;59, it is converted into hours and minutes.
 +
*Argument <math>SomeSecond</math> &gt;59, it is converted into hours, minutes and seconds.
 +
*If any arguments are invalid, Calci returns an #ERROR message.
 +
*If any argument is non-integer, it is truncated.
  
<nowiki>=TIME(R1C1, R1C2, R1C3)</nowiki>
 
  
TIME returns Tue Feb19 02:30:54 CST 2008.
+
== Examples ==
  
Consider another example (Column1, Row4)
+
*If the TIME() function is used in ZOS, following results are obtained.
  
<nowiki>=TIME(12,00,00)</nowiki>
+
<div id="6SpaceContent" class="zcontent" align="left">
  
TIME returns Tue Feb19 12:00:04 CST 2008.
+
{| id="TABLE3" class="SpreadSheet blue"
 +
|- class="even"
 +
| class="  " | '''Function'''
 +
| class="  " | '''Output'''
  
</div>
+
|- class="odd"
----
+
| class="sshl_f" |TIME(3,40,20)
<div id="10SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Syntax </div><div class="ZEditBox"><center></center></div></div>
+
| class="sshl_f" |0.15300925925839692
----
+
 
<div id="4SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Remarks </div></div>
+
|- class="even"
----
+
| class="sshl_f" |TIME(20,00,00)
<div id="3SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Examples </div></div>
+
| class="sshl_f" |0.8333333333284827
----
+
 
<div id="11SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Description </div></div>
+
|- class="odd"
----
+
| class="sshl_f" |TIME(-4,00,00)
<div id="2SpaceContent" class="zcontent" align="left">
+
| class="sshl_f" |0.8333333333284827
  
{| id="TABLE3" class="SpreadSheet blue"
 
 
|- class="even"
 
|- class="even"
| class=" " |
+
| class="sshl_f" |TIME(35,30,00)
| Column1
+
| class="sshl_f" |0.47916666666424135
| Column2
+
 
| Column3
 
| Column4
 
 
|- class="odd"
 
|- class="odd"
| class=" " | Row1
+
| class="sshl_f" |TIME(00,75,00)
| class=" " | 2
+
| class="sshl_f" |0.052083333328482695
| class=" " | 30
+
 
| class="sshl_f " | 54
 
| class=" " |
 
 
|- class="even"
 
|- class="even"
| class=" " | Row2
+
| class="sshl_f" |TIME(00,00,100)
| class="sshl_f" | Tue Feb 19 02:30:54 CST 2008
+
| class="sshl_f" |0.001157407408754807
| class="      " |
+
 
| class="        " |
 
| class=" " |
 
 
|- class="odd"
 
|- class="odd"
| Row3
+
| class="sshl_f" |TIME(3.5,40,00)
| class="   " |
+
| class="sshl_f" |0.15277777777373558
| class="         " |
+
|}
| class="   " |
+
 
| class=" " |
+
*If the TIME() function is used in Calci, following results are obtained.
 +
 
 +
<div id="6SpaceContent" class="zcontent" align="left">
 +
 
 +
{| id="TABLE3" class="SpreadSheet blue"
 
|- class="even"
 
|- class="even"
| Row4
+
| class="ssh1_f" |3
| class="sshl_f" | Tue Feb 19 12:00:00 CST 2008
+
| class=" " |20
| class=" " |
+
| class="  " |-2
| class=" " |
+
| class="  " |35
| class=" " |
+
| class="  " |00
 +
| class="  " |00
 +
| class=" " |3.5
 +
| class="  " |
 +
| class=" " |
 +
| class=" " |
 +
 
 
|- class="odd"
 
|- class="odd"
| class=" " | Row5
+
| class="ssh1_f" | 40
| class="       SelectTD ChangeBGColor SelectTD" |
+
| class=" " |00
<div id="2Space_Handle" class="zhandles" title="Click and Drag to resize CALCI Column/Row/Cell. It is EZ!"></div><div id="2Space_Copy" class="zhandles" title="Click and Drag over to AutoFill other cells."></div><div id="2Space_Drag" class="zhandles" title="Click and Drag to Move/Copy Area.">[[Image:copy-cube.gif]]  </div>
+
| class=" " |00
| class=" " |
+
| class=" " |30
| class=" " |
+
| class=" " |75
| class=" " |
+
| class=" " |00
 +
| class=" " |40
 +
| class=" " |
 +
| class=" " |
 +
| class=" " |
 +
 
 
|- class="even"
 
|- class="even"
| Row6
+
| class="ssh1_f" | 20
| class=" " |
+
| class="  " |00
| class=" " |
+
| class="  " |00
| class=" " |
+
| class="  " |00
| class=" " |
+
| class="  " |00
 +
| class="  " |90
 +
| class=" " |00
 +
| class=" " |
 +
| class=" " |
 +
| class=" " |
 
|}
 
|}
  
<div align="left">[[Image:calci1.gif]]</div></div>
+
=TIME(3,40,20) returns ''3:40:20 AM''
----
+
=TIME(20,00,00) returns ''8:00:00 PM''
 +
=TIME(-2,00,00) returns ''8:00:00 PM''
 +
=TIME(35,30,00) returns ''11:30:00 AM''
 +
=TIME(00,75,00) returns ''1:15:00 AM''
 +
=TIME(00,00,90) returns ''12:01:30 AM''
 +
=TIME(3.5,40,00) returns ''3:40:00 AM''
 +
 
 +
== See Also ==
 +
 
 +
*[[Manuals/calci/HOUR | HOUR]]
 +
*[[Manuals/calci/MINUTE | MINUTE]]
 +
*[[Manuals/calci/SECOND | SECOND]]
 +
*[[Manuals/calci/TIMEVALUE | TIMEVALUE]]
 +
 
 +
==References==
 +
 
 +
*[http://en.wikipedia.org/wiki/Time Time]

Revision as of 15:45, 26 December 2013

TIME(SomeHour, SomeMinute, SomeSecond)

where,

is a number that represents hour value

is a number that represents minute value

is a number that represents seconds value


TIME() returns the decimal number representing particular time or the time itself.


Description

TIME(SomeHour, SomeMinute, SomeSecond)

For Example,

TIME(2,30,54)

  • In ZOS, time value is returned as 0.10479166666482342
  • In Calci, time value is returned as 2:30:54 AM
  • Calci displays the time considering a 24 hour clock from 0:00:00 (12:00:00 AM) to 23:59:59 (11:59:59 PM).
  • The decimal output of time value is in the range from '0' to '0.99988426'. e.g. 12:00 PM is half of a day, represented as '0.5' or '0.25'.
  • If >23, it is divided by 24 and the remainder is considered as hour value. e.g. TIME(30,00,00) = 5 AM.
  • If is negative, it is subtracted from 23:59:59 and displayed as hour value.
  • If >59, it is converted into hours and minutes.
  • Argument >59, it is converted into hours, minutes and seconds.
  • If any arguments are invalid, Calci returns an #ERROR message.
  • If any argument is non-integer, it is truncated.


Examples

  • If the TIME() function is used in ZOS, following results are obtained.
Function Output
TIME(3,40,20) 0.15300925925839692
TIME(20,00,00) 0.8333333333284827
TIME(-4,00,00) 0.8333333333284827
TIME(35,30,00) 0.47916666666424135
TIME(00,75,00) 0.052083333328482695
TIME(00,00,100) 0.001157407408754807
TIME(3.5,40,00) 0.15277777777373558
  • If the TIME() function is used in Calci, following results are obtained.
3 20 -2 35 00 00 3.5
40 00 00 30 75 00 40
20 00 00 00 00 90 00

=TIME(3,40,20) returns 3:40:20 AM =TIME(20,00,00) returns 8:00:00 PM =TIME(-2,00,00) returns 8:00:00 PM =TIME(35,30,00) returns 11:30:00 AM =TIME(00,75,00) returns 1:15:00 AM =TIME(00,00,90) returns 12:01:30 AM =TIME(3.5,40,00) returns 3:40:00 AM

See Also

References