# Modern proper calendar control

**URL:** <https://forum.xojo.com/t/modern-proper-calendar-control/73307>\
**Category:** General\
**Created:** [November 20, 2022, 8:22pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307 "2022-11-20T20:22:07Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![PhilippeP](https://forum.xojo.com/user_avatar/forum.xojo.com/philippep/32/5348_2.png) [@PhilippeP](https://forum.xojo.com/u/PhilippeP)\
**Post date:** [November 26, 2022, 12:45pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/21 "2022-11-26T12:45:24Z")

</div>

> [@Pawel\_Soltysinski](#):
>
> ISO week number norm, which is not equal to Date.WeekOfYear in Xojo.

sorry can you explain US week number is not the same as europe ? i know in US starts on sunday, europe monday

i didn’t solve this equation to find out from wikipedia 😆

 ![image](https://forum.xojo.com/uploads/default/original/2X/1/11d16c9c57023595db92d3fed807e0164a8bcb7a.png)

---

<div class="post-metadata">

**Author:** ![TimStreater](https://forum.xojo.com/user_avatar/forum.xojo.com/timstreater/32/586_2.png) [@TimStreater](https://forum.xojo.com/u/TimStreater)\
**Post date:** [November 26, 2022, 12:47pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/22 "2022-11-26T12:47:17Z")

</div>

Well I don’t know about the US but in the UK we don’t do week numbers. They didn’t in the US either when I lived there but that was 30+ years ago.

---

<div class="post-metadata">

**Author:** ![Pawel\_Soltysinski](https://forum.xojo.com/user_avatar/forum.xojo.com/pawel_soltysinski/32/23522_2.png) [@Pawel\_Soltysinski](https://forum.xojo.com/u/Pawel_Soltysinski)\
**Post date:** [November 26, 2022, 10:22pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/24 "2022-11-26T22:22:24Z")

</div>

I once wrote a software to help people to plan shipments of good to customers in Europe. Since everyone is basing on “get it delivered on XX week” - I simply provided date.weekOfYear from Xojo when displaying weeks in a month since I wasn’t aware of whole ISO week numbering approach where first week of a given year is the one with first Thursday in January. Thus why I had to write this method.

---

<div class="post-metadata">

**Author:** ![Ivan\_Tellez](https://forum.xojo.com/letter_avatar_proxy/v4/letter/i/a9a28c/32.png) [@Ivan\_Tellez](https://forum.xojo.com/u/Ivan_Tellez)\
**Post date:** [November 26, 2022, 10:45pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/25 "2022-11-26T22:45:16Z")

</div>

> [@TimStreater](#):
>
> Well I don’t know about the US but in the UK we don’t do week numbers. They didn’t in the US either when I lived there but that was 30+ years ago.

Just because you don’t use it and you don’t know why others use it, doesn’t mean that an entire country doesn’t use it. 🤦🏻‍♂️

The UK even has a dedicated web site:

[https://weeknumber.co.uk/](https://weeknumber.co.uk/)

---

<div class="post-metadata">

**Author:** ![Nicholas\_Loveday](https://forum.xojo.com/letter_avatar_proxy/v4/letter/n/f1d935/32.png) [@Nicholas\_Loveday](https://forum.xojo.com/u/Nicholas_Loveday)\
**Post date:** [November 27, 2022, 4:06am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/26 "2022-11-27T04:06:23Z")

</div>

And here week numbers are counted from 1 July… I do all calendar calculations using Modified Julian Date.

If you’re into this stuff - and astronomy - you really should read Otto Neugebauer’s papers on the origins of the calendar and our time system.

IMHO the Egyptians got it right - a perpetual calendar with 3 seasons, each with 4 months of 30 days plus 5 holidays at the end of the year. Forget the leap years, and simply live with the fact the equinoxes shift slowly. Ditto leap seconds.

Better than the stupid mess we have now which clings to the notion that the equinoxes must occur on specific dates, and has a lot of trouble reconciling the civilian time system vs astronomical time vs atomic time standards (GPS).

Even better IMHO would be to ditch calendars entirely and run everything on Modified Julian Date.  
Life could be so much simpler.

But I expect the eurocrats that run the Bureau de l’Heure will inflict another complex mess on us all.

---

<div class="post-metadata">

**Author:** ![TimStreater](https://forum.xojo.com/user_avatar/forum.xojo.com/timstreater/32/586_2.png) [@TimStreater](https://forum.xojo.com/u/TimStreater)\
**Post date:** [November 27, 2022, 9:48am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/27 "2022-11-27T09:48:46Z")

</div>

> [@Ivan\_Tellez](#):
>
> Just because you don’t use it and you don’t know why others use it, doesn’t mean that an entire country doesn’t use it.

The only times I’ve heard anyone, anywhere, talk about week numbers was during operational meetings I attended in my last job, for a small company that provided the research internet for Europe. These might take place anywhere in Europe and when the meeting concluded, discussion about a date for the next meeting took place. Then, week numbers were mentioned.

As a tiny example, at meetings of our little Village Hall committee, no one uses week numbers. Everyone says “How about 23rd of next month” or similar. My wife is ona number of committees. Same thing.

---

<div class="post-metadata">

**Author:** ![Pawel\_Soltysinski](https://forum.xojo.com/user_avatar/forum.xojo.com/pawel_soltysinski/32/23522_2.png) [@Pawel\_Soltysinski](https://forum.xojo.com/u/Pawel_Soltysinski)\
**Post date:** [November 27, 2022, 1:29pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/28 "2022-11-27T13:29:42Z")

</div>

It probably all boils down to a specific business environment. The company for which I wrote the software for was constantly using the sentences “we will have two trucks for the XX week to pick up the goods” or “we can produce the goods for the XX week, not earlier” and so on. I didn’t know I created problem by using date.weekOfYear until one year they called on first week of January saying “your software is wrong, this is 1st week of 2022, not 2nd…”. I checked Calendar in MacOS and, indeed, it was numbering weeks their way. Just look at first full week of 2022 and see 1st week starts on 3rd of January.

---

<div class="post-metadata">

**Author:** ![Pawel\_Soltysinski](https://forum.xojo.com/user_avatar/forum.xojo.com/pawel_soltysinski/32/23522_2.png) [@Pawel\_Soltysinski](https://forum.xojo.com/u/Pawel_Soltysinski)\
**Post date:** [November 27, 2022, 2:38pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/29 "2022-11-27T14:38:12Z")

</div>

just look at Action event of this Repeat CheckBox. Unmark the top part with simple size change and mark the one with animate. thing, which does crash.

---

<div class="post-metadata">

**Author:** ![Jeff\_Tullin](https://forum.xojo.com/user_avatar/forum.xojo.com/jeff_tullin/32/693_2.png) [@Jeff\_Tullin](https://forum.xojo.com/u/Jeff_Tullin)\
**Post date:** [November 27, 2022, 6:38pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/30 "2022-11-27T18:38:41Z")

</div>

> The only times I’ve heard anyone, anywhere, talk about week numbers

It’s all anyone in a Payroll environment that pays people weekly , wants to talk about.  
Annoyingly, Week1 is the one that includes April 6  
It’s an enormous pain, especially when a ‘year’ has to include Week 53  
Constantly having to refer to this year’s calendar to know what they are talking about for (eg) Week 23

---

<div class="post-metadata">

**Author:** ![Ian\_Kennedy](https://forum.xojo.com/user_avatar/forum.xojo.com/ian_kennedy/32/6860_2.png) [@Ian\_Kennedy](https://forum.xojo.com/u/Ian_Kennedy)\
**Post date:** [November 28, 2022, 10:39am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/31 "2022-11-28T10:39:21Z")

</div>

Again, I’m in the UK and the only week number I’ve ever come across is an academic one. It was nothing to do with the website you pointed at. That site is in no way official, all government sites run on [gov.uk](http://gov.uk) domain.

Academic week numbers begin in September with the start of term and run until August the next year. You can buy academic calendars that run this way. There is also a government website about it:

> **[Understanding academic years](https://www.gov.uk/guidance/understanding-academic-years)**
>
> Information for students to help work out what academic year their course falls under.

---

<div class="post-metadata">

**Author:** ![Nicholas\_Loveday](https://forum.xojo.com/letter_avatar_proxy/v4/letter/n/f1d935/32.png) [@Nicholas\_Loveday](https://forum.xojo.com/u/Nicholas_Loveday)\
**Post date:** [December 27, 2022, 12:32am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/32 "2022-12-27T00:32:57Z")

</div>

Here - in a government department - we do use week numbers but there’s a catch - they start at July 1, and I think it’s an old hangover from the days when planning was done in MS Excel and MS Project, 30 years ago.

Railways are notoriously conservative and very slow to change old habits.

---

<div class="post-metadata">

**Author:** ![Pawel\_Soltysinski](https://forum.xojo.com/user_avatar/forum.xojo.com/pawel_soltysinski/32/23522_2.png) [@Pawel\_Soltysinski](https://forum.xojo.com/u/Pawel_Soltysinski)\
**Post date:** [December 27, 2022, 8:04am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/33 "2022-12-27T08:04:27Z")

</div>

Interesting. Can you elaborate?

---

<div class="post-metadata">

**Author:** ![Rick\_Araujo](https://forum.xojo.com/user_avatar/forum.xojo.com/rick_araujo/32/251_2.png) [@Rick\_Araujo](https://forum.xojo.com/u/Rick_Araujo)\
**Post date:** [December 27, 2022, 11:27am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/34 "2022-12-27T11:27:08Z")

</div>

> [@Nicholas\_Loveday](#):
>
> there’s a catch - they start at July 1

Fiscal Year? [Fiscal Year: What It Is and Advantages Over Calendar Year](https://www.investopedia.com/terms/f/fiscalyear.asp)

---

<div class="post-metadata">

**Author:** ![Ian\_Kennedy](https://forum.xojo.com/user_avatar/forum.xojo.com/ian_kennedy/32/6860_2.png) [@Ian\_Kennedy](https://forum.xojo.com/u/Ian_Kennedy)\
**Post date:** [December 27, 2022, 2:52pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/35 "2022-12-27T14:52:31Z")

</div>

Tax year starts on April 5th.

---

<div class="post-metadata">

**Author:** ![Jeremie\_L](https://forum.xojo.com/user_avatar/forum.xojo.com/jeremie_l/32/150_2.png) [@Jeremie\_L](https://forum.xojo.com/u/Jeremie_L)\
**Post date:** [December 27, 2022, 2:56pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/36 "2022-12-27T14:56:44Z")

</div>

Fiscal year has nothing to do with tax year.  
And to be completely accurate, in the UK, tax year starts in **April 6th**. But that is **not** the case in other countries.

---

<div class="post-metadata">

**Author:** ![Ian\_Kennedy](https://forum.xojo.com/user_avatar/forum.xojo.com/ian_kennedy/32/6860_2.png) [@Ian\_Kennedy](https://forum.xojo.com/u/Ian_Kennedy)\
**Post date:** [December 27, 2022, 3:10pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/37 "2022-12-27T15:10:44Z")

</div>

I didn’t claim it did. Just pointing out that year starts can be even on none month boundaries. True about the 6th though.

---

<div class="post-metadata">

**Author:** ![TimStreater](https://forum.xojo.com/user_avatar/forum.xojo.com/timstreater/32/586_2.png) [@TimStreater](https://forum.xojo.com/u/TimStreater)\
**Post date:** [December 27, 2022, 6:32pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/38 "2022-12-27T18:32:27Z")

</div>

So, as I stated before, in general in the UK we do not use the expression “week number”, and it seems that when we do, what that means precisely depends on the environment. None of the UK examples cited so far have any correspondance with what continental Europeans mean by “week number”.

---

<div class="post-metadata">

**Author:** ![Nicholas\_Loveday](https://forum.xojo.com/letter_avatar_proxy/v4/letter/n/f1d935/32.png) [@Nicholas\_Loveday](https://forum.xojo.com/u/Nicholas_Loveday)\
**Post date:** [December 27, 2022, 9:37pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/39 "2022-12-27T21:37:27Z")

</div>

This case is a very large government-owned passenger railway where the vast majority of the construction and maintenance work is planned to occur on weekends - **for as far out as 5-10 years in advance** , and there are a large number of external contractor organisations involved.

Using week numbers was a historical habit across the organisation and contractors - while the work is planned in SAP, various views of that data are extracted to various formats for easy distribution externally, mainly Excel or PDF tables.

Software-wise I just use a Julian Date (as a double) for everything using Meeus’ formulas, down to the second.

---

<div class="post-metadata">

**Author:** ![Rick\_Araujo](https://forum.xojo.com/user_avatar/forum.xojo.com/rick_araujo/32/251_2.png) [@Rick\_Araujo](https://forum.xojo.com/u/Rick_Araujo)\
**Post date:** [December 27, 2022, 10:26pm UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/40 "2022-12-27T22:26:15Z")

</div>

> [@Nicholas\_Loveday](#):
>
> Software-wise I just use a Julian Date (as a double) for everything using Meeus’ formulas, down to the second.

So it seems moon based instead of solar based or something hybrid. Weird these days, at least in western countries.

---

<div class="post-metadata">

**Author:** ![Julia\_Truchsess](https://forum.xojo.com/user_avatar/forum.xojo.com/julia_truchsess/32/499_2.png) [@Julia\_Truchsess](https://forum.xojo.com/u/Julia_Truchsess)\
**Post date:** [December 28, 2022, 3:09am UTC](https://forum.xojo.com/t/modern-proper-calendar-control/73307/41 "2022-12-28T03:09:08Z")

</div>

> [@TimStreater](#):
>
> The only times I’ve heard anyone, anywhere, talk about week numbers was during operational meetings I attended in my last job, for a small company that provided the research internet for Europe.

Week number is very widely used in industry to indicate “date of manufacture” in year-week format. You’ll find it on many products’ “date code” or serial number.

[Previous page](https://forum.xojo.com/t/modern-proper-calendar-control/73307.md?page=1)

[Next page](https://forum.xojo.com/t/modern-proper-calendar-control/73307.md?page=3)
