forked from amazingfate/help
Patch contributed by Oliver Rainer-Wittmann
i#118572 - remove ui string and help content regarding
usage of Java Mail in Writer's Mail Merge as Java
Mail is not used.
http://svn.apache.org/viewvc?view=revision&revision=1197035
Patches contributed by Herbert Duerr
updated help text for regexp word boundaries
http://svn.apache.org/viewvc?view=revision&revision=1228026
improved help text for word boundary regexp expression \b
http://svn.apache.org/viewvc?view=revision&revision=1234738
Patches contributed by Jurgen Schmidt
remove onlineregistration with dependencies
http://svn.apache.org/viewvc?view=revision&revision=1240245
Patch contributed by Regina Henschel
Extended tips for corner and cap style
http://svn.apache.org/viewvc?view=revision&revision=1242287
* re-enable on-line update help, remove obsolete on-line purchasing.
184 lines
7.9 KiB
XML
184 lines
7.9 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
|
|
<!--
|
|
* This file is part of the LibreOffice project.
|
|
*
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
*
|
|
* This file incorporates work covered by the following license notice:
|
|
*
|
|
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
* contributor license agreements. See the NOTICE file distributed
|
|
* with this work for additional information regarding copyright
|
|
* ownership. The ASF licenses this file to you under the Apache
|
|
* License, Version 2.0 (the "License"); you may not use this file
|
|
* except in compliance with the License. You may obtain a copy of
|
|
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
-->
|
|
|
|
<helpdocument version="1.0">
|
|
<meta>
|
|
<topic id="textsbasicshared03030120xhp" indexer="include" status="PUBLISH">
|
|
<title id="tit" xml-lang="en-US">DateDiff Function [Runtime]</title>
|
|
<filename>/text/sbasic/shared/03030120.xhp</filename>
|
|
</topic>
|
|
<history>
|
|
<created date="2005-04-25T13:20:42">DateDiff</created>
|
|
<lastedited date="2005-04-26T10:55:34">checked</lastedited>
|
|
</history>
|
|
</meta>
|
|
<body>
|
|
<section id="datediff">
|
|
<bookmark xml-lang="en-US" branch="index" id="bm_id6134830"><bookmark_value>DateDiff function</bookmark_value>
|
|
</bookmark>
|
|
<paragraph role="heading" id="par_idN10542" xml-lang="en-US" level="1" l10n="NEW"><link href="text/sbasic/shared/03030120.xhp">DateDiff Function [Runtime]</link></paragraph>
|
|
<paragraph role="paragraph" id="par_idN10546" xml-lang="en-US" l10n="NEW">Returns the number of date intervals between two given date values.</paragraph>
|
|
</section>
|
|
<paragraph role="heading" id="par_idN10549" xml-lang="en-US" level="2" l10n="NEW">Syntax:</paragraph>
|
|
<bascode>
|
|
<paragraph role="bascode" id="par_idN10648" xml-lang="en-US">DateDiff (Add, Date1, Date2 [, Week_start [, Year_start]])</paragraph>
|
|
</bascode>
|
|
<paragraph role="heading" id="par_idN1064B" xml-lang="en-US" level="2" l10n="NEW">Return value:</paragraph>
|
|
<paragraph role="paragraph" id="par_idN1064F" xml-lang="en-US" l10n="NEW">A number.</paragraph>
|
|
<paragraph role="heading" id="par_idN10652" xml-lang="en-US" level="2" l10n="NEW">Parameters:</paragraph>
|
|
<paragraph role="paragraph" id="par_idN10656" xml-lang="en-US" l10n="NEW">
|
|
<emph>Add</emph> - A string expression from the following table, specifying the date interval.</paragraph>
|
|
<embed href="text/sbasic/shared/03030110.xhp#datetable"/>
|
|
<paragraph role="paragraph" id="par_idN10664" xml-lang="en-US" l10n="NEW">
|
|
<emph>Date1, Date2</emph> - The two date values to be compared.</paragraph>
|
|
<section id="weekyear">
|
|
<paragraph role="paragraph" id="par_idN1066A" xml-lang="en-US" l10n="NEW">
|
|
<emph>Week_start</emph> - An optional parameter that specifies the starting day of a week. </paragraph>
|
|
<table id="tbl_id8356883">
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablehead" id="par_idN1067A" xml-lang="en-US" l10n="NEW">Week_start value</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablehead" id="par_idN10680" xml-lang="en-US" l10n="NEW">Explanation</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10687" xml-lang="en-US" l10n="NEW">0</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN1068D" xml-lang="en-US" l10n="NEW">Use system default value</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10694" xml-lang="en-US" l10n="NEW">1</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN1069A" xml-lang="en-US" l10n="NEW">Sunday (default)</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106A1" xml-lang="en-US" l10n="NEW">2</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106A7" xml-lang="en-US" l10n="NEW">Monday</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106AE" xml-lang="en-US" l10n="NEW">3</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106B4" xml-lang="en-US" l10n="NEW">Tuesday</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106BB" xml-lang="en-US" l10n="NEW">4</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106C1" xml-lang="en-US" l10n="NEW">Wednesday</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106C8" xml-lang="en-US" l10n="NEW">5</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106CE" xml-lang="en-US" l10n="NEW">Thursday</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106D5" xml-lang="en-US" l10n="NEW">6</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106DB" xml-lang="en-US" l10n="NEW">Friday</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106E2" xml-lang="en-US" l10n="NEW">7</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN106E8" xml-lang="en-US" l10n="NEW">Saturday</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
</table>
|
|
|
|
<paragraph role="paragraph" id="par_idN106EB" xml-lang="en-US" l10n="NEW">
|
|
<emph>Year_start</emph> - An optional parameter that specifies the starting week of a year. </paragraph>
|
|
<table id="tbl_id1173436">
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablehead" id="par_idN106FB" xml-lang="en-US" l10n="NEW">Year_start value</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablehead" id="par_idN10701" xml-lang="en-US" l10n="NEW">Explanation</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10708" xml-lang="en-US" l10n="NEW">0</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN1070E" xml-lang="en-US" l10n="NEW">Use system default value</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10715" xml-lang="en-US" l10n="NEW">1</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN1071B" xml-lang="en-US" l10n="NEW">Week 1 is the week with January, 1st (default)</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10722" xml-lang="en-US" l10n="NEW">2</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10728" xml-lang="en-US" l10n="NEW">Week 1 is the first week containing four or more days of that year</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
<tablerow>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN1072F" xml-lang="en-US" l10n="NEW">3</paragraph>
|
|
</tablecell>
|
|
<tablecell colspan="" rowspan="">
|
|
<paragraph role="tablecontent" id="par_idN10735" xml-lang="en-US" l10n="NEW">Week 1 is the first week containing only days of the new year</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
</table>
|
|
|
|
</section>
|
|
<paragraph role="heading" id="par_idN10738" xml-lang="en-US" level="2" l10n="NEW">Example:</paragraph>
|
|
<bascode>
|
|
<paragraph role="bascode" localize="false" xml-lang="en-US">Sub example_datediff</paragraph>
|
|
<paragraph role="bascode" localize="false" xml-lang="en-US"> MsgBox DateDiff("d", "1/1/2005", "12/31/2005")</paragraph>
|
|
<paragraph role="bascode" localize="false" xml-lang="en-US">End Sub</paragraph>
|
|
</bascode>
|
|
</body>
|
|
</helpdocument>
|