At 20:24 03/04/2020 -0400, Peter Dutton wrote:
Here's a formula I'm using
=DATEDIF($Begin_Here.$E$76,R4,"d")

The above formula returns the day number of the year where $Begin_Here.$E$76 [...] the date of 12/31/19

Cell R4 has the date 10 (which is Monday, February 10, 2020)

"10" is not a date - unless you mean the date that is internally stored as the number 10, which would be 9 January 1900! And that would be an error for the function, since the end date needs to be later than the start date.

"d" is the interval

Well, it's the unit in which you want the returned interval specified.

Wouldn't it be easier to use
=DAYS("2020-02-10";$Begin_Here.$E$76)
or just
="2020-02-10"-$Begin_Here.$E$76
?

Even more easily, abandon your "Begin_Here" value and try (with your 10 February 2020 date in R4)
=R4-DATE(YEAR(R4)-1;12;31)
This will produce the number 41 - providing the result cell is appropriately formatted.

It would be nice to have a / (forward slash) after the day number of the year which is returned by the above formula. How can this be done?

You can concatenate strings using the "&" operator, so just put &"/" after any of these formulae, such as
=R4-DATE(YEAR(R4)-1;12;31)&"/"
The numerical value 41 is implicitly converted to a string and concatenated with the slash to create the *string* 41/ .

I trust this helps.

Brian Barker


--
To unsubscribe e-mail to: [email protected]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy

Reply via email to