Prefix any of the week tokens with the letter "s" (s for start), to have these tokens appear only on the first day of the week, as defined by the [sw] token GridOptions.
On other days the token converts to a blank. Note that this is not a zap token; blank means no text.
Some examples:
•On Monday, August 1, [sw] = 30, and in English [sWeek] = Week.
•Tuesday, August 2, [sw], [sWk], [sWeek] are all blank.
•One way to use the [sw] token is in a daily diary where you only want the week number to appear at the beginning of a new week. For example the tokens [sWeek] [sw] would be blank on any day except at the beginning of the week, where they would combine to give, for example Week 34.
Appear on weekdays other than Mondays
You can specify that the [sw] token should appear on a different weekday than Monday by adding the :0X suffix to the [sw] token, where X can be any number from 1 (Monday) to 7 (Sunday), or by using the [sw] token GridOptions.
In some cases, you might want to show the week number on the first day of some months as well as the first day of the week.
➢This is quite common in monthly grids, such as the one in the example above right, where the week number must appear on the first day of the month, as well as every Monday.
The above is done by adding a colon ":" and one of the followings characters at the end of the token.
Character |
Example |
Description |
---|---|---|
m |
[sw:m] |
Show the week number on the first day of the week and also on the first day of every month. |
3 |
[sWeek:3] |
Show the translation of the word "week" on the first day of the week and also on the first day of every 3 months. |
6 |
[sWk:6] |
Show the abbreviated form of the translation of the word "week" on the first day of the week and also on the first day of every 6 months. |
y |
[sw:y] |
Show the week number on the first day of the week and also on the first day of the year. |
Moving the position of the week number based on other events
You can use :~ suffixes to move the week number from its default position, usually Monday, to the first available place that has a certain number of days without any other event occurring (such as holidays or moon phases, for example).
The structure of these suffixes is one of the 3 following:
:~DayCount_SetOfEvents
or
:~DayCount-SetOfEvents
or
:~DayCount/SetOfEvents
where
DayCount |
This is a number from 1 to 7 indicating how many consecutive days, including the current one, must not contain any event from the SetOfEvents to display a week number.
If no number is specified, then the default value of 1 is assumed (ie. the week number will be displayed on the 1st day that does not contain any event from the SetOfEvents) and no underscore should be used. |
||||||||||||||||||
_ - / |
|
||||||||||||||||||
SetOfEvents |
This is a series of letters corresponding to the various events that may cause a diary design to require the week number to be moved by one or more days. These letters are the same as those used in holidays response tokens, and are as follows:
|
Finally, note that Q++Studio lets you decide, for each DiaryGridLine, what the first day of the week is, using the property option week starts on.
Topic 087052, last updated on 03-Feb-2021