Please enable JavaScript to view this site.

 

Navigation: Script Line Properties > Holidays (multiple)

Text/Tokens Surrounding each Holiday Name

Scroll Prev Up Next More
At the bottom of the holidays (multiple) property editor, as shown on the right, are the the Text/Tokens Surrounding each Holiday Name settings, where you can specify text and/or tokens that should surround each holiday occurrence, if the processing of an individual holiday token generates multiple holidays.

 

Usually, you should not include a LanguageTag and/or DayValue in the tokens that you place here. The LanguageTag and DayValue of the originating holiday name token will automatically be assumed. For example, if the original token was [6fa], then the use of [d] [ddd] [mmm] in the text surrounding the holiday name would be treated as [a6d] [a6ddd] [a6mmm].

If you do specify a LanguageTag in the tokens here, then this LanguageTag will override the LanguageTag of the originating holiday name token (and then you will need to specify a DayValue, usually 1, to use the DayValue of the originating token).

If you do specify a DayValue in the tokens here, then this DayValue will override the DayValue of the originating holiday name token.

As always, any underscore character "_" (without the quotes) contained in this string will be replaced by a non-breaking space.

You can use macro tokens (and then you will need to specify a DayValue, usually 1, to use the DayValue of the originating token).

You can mix special character markers with the tokens.

You can use recursive tokens.

 

Overriding LanguageTags or DayValues

 

As mentioned, usually, you would not include a LanguageTag and/or DayValue in the tokens that you place here, but in some cases, it might be required.

 

If some of the tokens you wish to display here depend on language (such as the [ddd] and [mmm] tokens) you should use a LanguageTag in the original token, for example using [b6fa] as holiday token to ensure that the surrounding tokens get converted to [b6d] [b6ddd] [b6mmm].

If you wish to use a different language than the language of the original token (for example c instead of b) then you must include a DayValue of 1 to your token, that is to say, use [c1ddd], instead of [ddd], for example.

The same is true if you need to add a macro to the tokens before/after each holiday. In such cases, the DayValue 1 should be used, that is to say, the incorrect token [*2ddd] should instead be [1*2ddd], otherwise a run-time error message will be generated.

 

Displaying Holidays Symbols and Abbreviations

 

For simple cases, you can display holiday symbols and/or abbreviations near each occurrence, using the property holidays (display).

 

Alternatively, you can insert the sequential version of the symbol tokens or abbreviation tokens, with XX as placeholders that will be replaced at run-time.

 

So, for example you could use [ûXX], as shown on the right, to display the holiday symbol corresponding to each individual occurrence of the multiple holidays.

 

Similarly, you could use [fûXX] to display the holiday abbreviation corresponding to each individual occurrence of the multiple holidays.

 

Combining consecutive dates with the same holiday name

 

Q++Studio can combine consecutive holiday occurrences returned by a holiday token into a single entry showing the first and last dates and their common holiday name, as shown in the example on the right.

 

The occurrences may come from either a single multi-day holiday rule or several separate holiday rules. They only need to occur on consecutive dates and have the same resulting holiday name.

 

If separate holiday rules normally have different names, the ALWAYS holiday name variation can be used to give them the same resulting name. For example, separate rules for Maundy Thursday, Good Friday, Holy Saturday, Easter Sunday and Easter Monday could each contain:

 

 >>>ALWAYS=Easter Holidays

 

Their consecutive dates could then be combined and displayed as a single entry, such as:

 

 28.–31.3.: Easter Holidays

 

The Repeated Name Holiday Editor

 

Click the ellipsis button beside the left and right text fields of the holidays (multiple) property editor.

 

The resulting editor contains one field for individual dates and three fields for combined sequences: dates in the same month, dates in different months, and dates in different years (the idea is similar to MonthHeaders).

 

Once again, if consecutive dates come from different holiday rules, use the ALWAYS holiday name variation on each rule if necessary, so that all occurrences have the same resulting name and can therefore be combined.

 

First and last date Tokens

 

In the three combined fields, use:

 

DayValue 000 to indicate the first date.

DayValue 999 to indicate the last date.

 

Otherwise, these fields accept the same LanguageTags, macro tokens and special character markers as the standard surrounding-text fields.

 

Note that, the text editor changes, as shown above, as soon as one of the 3 multi-day fields is non-blank.

 

Override hyphen with

 

Sometimes you may want to join repeated holidays one way if they are just 1 day apart, and another way if the range of dates is more than 2 days.

 

the "Override hyphen with" option assumes you are using a hyphen where you specify text and/or tokens surrounding each holiday occurrence.

if you need a hyphen as joiner, then you do not need to specify it (but you can, if you prefer, for clarity).

 

In the example on the right, 2-day periods are separated with a forward slash  "/", while periods spanning more than 2 days are separated with a hyphen "-".

 

See also: concatenating holidays dates with a macro, examples of the use of the holidays (display/multiple) properties.

 


Topic 107088, last updated on 12-Sep-2026