Calculate remaining days

Hi everybody,

I know that this is a very well disscussed subject, and that there are a lot of topics and templates online, but I cannot calculate the remaining days between:

a) now and an expiry date;
b) a date and the expiry date.

Used the formula DAYS(Date2; Date1) or DAYS(NOW; Date1), everytime same error: #VALUE!
Generate #VALUE! error in Tools - Options - LibreOffice Calc - Formula is not selected; both date fields selected as date, Romanian (DD.MM.YYYY); result cell selected as number, general.

I suppose there are bugs, but have the last version 7.6.4.1
Please help, I`m desperate.

Much apprecited, thank you and best regards.

Please upload an example file and indicate the cell with the formula that returns an error.

test.ods (10.6 KB)

Thank you so much for your kind support and understanding!

Welcome!

Just press Ctrl+F8 or choose View - Value Highlighting

1 Like

So, cell A4 contains the text (string) 15.06.2024.
The formula in cell B5 contains NOW instead of NOW().
Must be

=DAYS(NOW(); A5)

or

=NOW()-A5
1 Like

Thank you for your kind response! Actually tried in many ways during several days, have random issues… for example the formating is often different… does not stay on date for example…

Now,a fter correcting again the formula, it shows 0. :roll_eyes:

Thank you for your kind reply! Then, what kind of bug is this? Now my dates are in black… checked, are formatted as Number, Standard, although left all saved as dates… :angry:

When opened the document again, some dates were formated with date and time…

Non-blank cells (not formulas) in Calc have only two types of values: number and text (string). Formatting a cell does not change the value type. If you have entered text into a cell (even if it looks like a number or date), then changing the cell format cannot turn this text into a number.

1 Like

Thank you all!!! Worked after several retries.

1 Like