Please enable JavaScript to view this site.

 

Navigation: Script Line Properties > Macros Options > Resulting Actions

Macros Resulting nResult Actions

Scroll Prev Up Next More
The nResult Actions are specified in the resulting actions tab of the macro tokens rules dialog. They are used to specify how the value of the nRESULT variable should be used when processing a macro token.

 

Since nRESULT is of type integer, it is usually used to calculate a date. However this option is very rarely needed unless you need to override the Q++Studio calculation of token dates.

 

This occurs, for example in diaries where dates may need to be skipped. Consider, for example the grid below, which is basically a 4 days on 2 pages diary.

 

But as can be seen from the figure on the right, this diary has the added twist that the first of the month must always be at the top right (in the DayValue 3 position), and a month preview calendar must always precede the first of the month (in the DayValue 2 position).

 

       

 

In such cases the running date must be calculated explicitly in a macro to be able to skip dates as necessary. Again, it must be stressed that the use of these options is rarely necessary except in the most weird cases where a macro must be written to calculate dates instead of letting Q++Studio do it.

   

Currently the options available are:

 

Do Nothing

Self explanatory and the most common setting.

Ignore value of nResult

Same as the above, but choosing this option tells Q++Studio that you voluntarily decided to ignore the value of nResult which gets rid of a run-time message that warns you about setting a value for nResult but using Do Nothing in both cases.

Change date of Tokens

in sRESULT

Use this option to modify the date of any tokens that are included in the text value of sResult. This is useful to ensure that all recursive tokens that result from a macro have the date you wish.

Change date of subsequent Minicalendars

Use this option to modify the date of any minicalendars that follow the current macro token (click here for an example).

Change color of text

Use this option to modify the color of the text result. The value of nResult must correspond to the 24-bit color value as displayed in the templates explorer.

Change textbox background color

Use this option to modify the color of the textbox that contains the current macro token. The value of nResult must correspond to the 24-bit color value as displayed in the templates explorer.

Change both text and background color

Use this option to modify the color of the text result and of the textbox that contains the current macro token. The value of nResult must correspond to the 24-bit color value as displayed in the templates explorer. This option only makes sense if either the text or the background has a shade value different of 100%, otherwise the text will be the same color as the background (ie. it will be invisible).

 

See also: text actions, text style actions,  and box actions, .

 


Topic 173780, last updated on 02-Apr-2023