MoonPoint Support Logo

 

Shop Amazon Warehouse Deals - Deep Discounts on Open-box and Used ProductsAmazon Warehouse Deals



Advanced Search
March
Sun Mon Tue Wed Thu Fri Sat
5
       
2015
Months
Mar


Thu, Mar 05, 2015 8:04 pm

Calc and datedif

The Apache OpenOffice spreadsheet program Calc as of the current 4.1.1 version does not provide the DATEDIF function found in Microsoft Office Excel and Google Sheets. The datedif function can be used to calculate the number of days between two dates in Excel.

Calc does provide a NETWORKDAYS function, but that gives you the number of work days between two dates. I.e., weekends are excluded.

NETWORKDAYS

Returns the number of workdays between a start date and an end date. Holidays can be deducted.

Syntax

NETWORKDAYS(StartDate; EndDate; Holidays)

StartDate is the date from when the calculation is carried out. If the start date is a workday, the day is included in the calculation.

EndDate is the date up until when the calculation is carried out. If the end date is a workday, the day is included in the calculation.

Holidays is an optional list of holidays. These are non-working days. Enter a cell range in which the holidays are listed individually.

Example

How many workdays fall between 2001-12-15 and 2002-01-15? The start date is located in C3 and the end date in D3. Cells F3 to J3 contain the following Christmas and New Year holidays: "2001-12-24", "2001-12-25", "2001-12-26", "2001-12-31", "2002-01-01".
=NETWORKDAYS(C3;D3;F3:J3) returns 17 workdays.

However, the DATEDIF function isn't needed to calculate the number of days between two dates in Calc. Instead, you can simply subtract the two dates. E.g., if cell B18 contains the date January 1, 2014 and cell B19 contains the date March 4, 2015, you could place the formula =B19 - B18 in the cell where you want to store the number of days between the two dates. Unless you change the formatting of the cell to be something other than a number, you will see 427 as the value in the cell with that formula given the stated dates. That forumula will produce a result equivalent to DATEDIF(Start_Date,End_Date,"d") in Excel.

[/software/openoffice] permanent link

Thu, Mar 05, 2015 2:09 pm

Referencing a Google sheet with a space in the name

If you are using Google Sheets, which is Google's free, web-based spreadsheet program, for a spreadsheet and need to reference a sheet in a workboook that has a space in the name from another sheet, you need to enclose the name of the sheet in single quotes. E.g., if I have a sheet named 2014 MoonPoint and need to reference a cell, e.g., D292, in that sheet from another sheet, I could use '2014 Moonpoint'!D292 to reference the cell from which I need to obtain information. You will also need to use single quotes to enclose the name if you have other non-alphanumeric characters in the name, i.e., if you use other characters besides letters and numbers in the name.

[/network/web/services/google] permanent link

Valid HTML 4.01 Transitional

Privacy Policy   Contact

Blosxom logo