Calc - Conditional formatting - start of the week -> why not Monday?

When i creating a Conditional Formatting in Calc for date (condition. next week), then Sunday is defined as the start of the week.

In the operating system (W10) Monday is defined as the start of the week.

Am I still missing a setting for the start of the week, Sunday or Monday or is this a bug.



90040 HB Kap 04 Testdatei Datum.ods (16,7 KB)


Version: 7.5.2.2 (X86_64) / LibreOffice Community
Build ID: 53bb9681a964705cf672590721dbc85eb4d0c3a2
CPU threads: 8; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: de-DE (de_DE); UI: de-DE
Calc: CL threaded

Excel behaves the same way.

Aktuelle Kalenderwoche

1 Like

My printed calendars all start on Sunday but ISO week date - Wikipedia says “Weeks start with Monday and end on Sunday.” Biblically speaking, I guess that’s right but because of compatibility with Excel…

Bug 119407 - Allow flexible start-of-week days in Previous/This/Next Week conditional formattings

1 Like

simple workaround:
sorry the formula should read:

INT((B1-2)/7)-1 = INT(NOW()/7)

2 Likes

@PKG ; @EarnestAl ; @karolus

First of all, thank you very much for your contributions.

  • Excel solution
  • Bug
  • Workaround

Since I need it for documentation, I will point out the bug.

What will happen to the formula on 2023-04-08?

1 Like

good catch! … each bracket counts, the correct formula is
INT((B1-2)/7)-1 = INT(NOW()/7)

I think the correct formula is

=INT((B1-2)/7)=INT((TODAY()+5)/7)

with the same idea (provided that in the Calc parameters, the 0th day corresponds to 1899-12-30).

formally, given that the epoch can have three different starts in Calc, each on own weekday, the correct and compatible (i.e., working in Excel, even in 1904-01-01-base files), but slower, formula would be

INT((B1-DATEVALUE("1904-01-04"))/7)=INT((TODAY()+7-DATEVALUE("1904-01-04"))/7)

relying on the fact that 1904-01-04 is a (~randomly chosen) Monday no earlier than the latest possible epoch.

1 Like

OTOH, the WEEKS function with Type parameter 1 is created specifically for this:

WEEKS(TODAY();B1;1)=1
2 Likes