Difference between revisions of "Documentation/How Tos/Calc: DAYS360 function"

From Apache OpenOffice Wiki
Jump to: navigation, search
m (Example:)
m
 
(10 intermediate revisions by 6 users not shown)
Line 1: Line 1:
__NOTOC__
+
{{DISPLAYTITLE: DAYS360 function}}
 +
{{Documentation/CalcFunc DateTimeTOC
 +
|ShowPrevNext=block
 +
|PrevPage=Documentation/How_Tos/Calc:_DAYS_function
 +
|NextPage=Documentation/How_Tos/Calc:_DAYSINMONTH_function
 +
}}__NOTOC__
  
 
== DAYS360 ==
 
== DAYS360 ==
Line 8: Line 13:
 
: <tt>'''startdate'''</tt> and <tt>'''enddate'''</tt> are the starting and ending dates (text or date-time serial numbers). If <tt>'''startdate'''</tt> is earlier than <tt>'''enddate'''</tt>, the result will be negative.
 
: <tt>'''startdate'''</tt> and <tt>'''enddate'''</tt> are the starting and ending dates (text or date-time serial numbers). If <tt>'''startdate'''</tt> is earlier than <tt>'''enddate'''</tt>, the result will be negative.
  
: <tt>'''method'''</tt> is an optional parameter; if <tt>'''0'''</tt> or omitted, the US / National Association of Securities Dealers (NASD) method of calculation is used; if <tt>'''1'''</tt> (or <>0) the European method of calcuation is used.
+
: <tt>'''method'''</tt> is an optional parameter; if <tt>'''0'''</tt> or omitted, the US National Association of Securities Dealers (NASD) method of calculation is used; if <tt>'''1'''</tt> (or <>0) the European method of calcuation is used.
  
 
: The calculation assumes that all months have 30 days, so a year (12 months) has 360 days.
 
: The calculation assumes that all months have 30 days, so a year (12 months) has 360 days.
 +
 +
: See [[Documentation/How_Tos/Calc: Date & Time functions#Financial date systems|Financial date systems]] for more details.
  
 
=== Example: ===
 
=== Example: ===
Line 16: Line 23:
 
: returns <tt>'''180'''</tt>, that is, 6 months of 30 days.
 
: returns <tt>'''180'''</tt>, that is, 6 months of 30 days.
  
=== See also: ===
+
{{SeeAlso|EN|
'''[[Documentation/How_Tos/Calc: DAYS function|DAYS]]''',
+
* [[Documentation/How_Tos/Calc: DAYS function|DAYS]]
'''[[Documentation/How_Tos/Calc: NETWORKDAYS function|NETWORKDAYS]]'''
+
* [[Documentation/How_Tos/Calc: NETWORKDAYS function|NETWORKDAYS]]
 +
 
 +
* [[Documentation/How_Tos/Calc: Date & Time functions#Date and Time overview|Date & Time overview]]
 +
 
 +
* [[Documentation/How_Tos/Calc: Date & Time functions|Date & Time functions]]
  
'''[[Documentation/How_Tos/Calc: Date & Time functions|Date & Time functions]]'''
+
* [[Documentation/How_Tos/Calc: Date & Time functions#Financial date systems|Financial date systems]]
  
'''[[Documentation/How_Tos/Calc: Date & Time functions#Date and Time overview|Date & Time overview]]'''
+
* [[Documentation/How_Tos/Calc: Functions listed alphabetically|Functions listed alphabetically]]
 +
* [[Documentation/How_Tos/Calc: Functions listed by category|Functions listed by category]]}}
 +
[[Category: Documentation/Reference/Calc/Date and Time functions]]

Latest revision as of 13:59, 30 January 2024



DAYS360

Returns the number of days between two dates, using the 360 day year.

Syntax:

DAYS360(enddate; startdate; method)

startdate and enddate are the starting and ending dates (text or date-time serial numbers). If startdate is earlier than enddate, the result will be negative.
method is an optional parameter; if 0 or omitted, the US National Association of Securities Dealers (NASD) method of calculation is used; if 1 (or <>0) the European method of calcuation is used.
The calculation assumes that all months have 30 days, so a year (12 months) has 360 days.
See Financial date systems for more details.

Example:

DAYS360("2008-02-29"; "2008-08-31")

returns 180, that is, 6 months of 30 days.



See Also
Retrieved from "https://wiki.openoffice.org/w/index.php?title=Documentation/How_Tos/Calc:_DAYS360_function&oldid=259702"
Views
Personal tools
Navigation
Tools