Question around Table Parameters

So it seems that I have noticed something around table parameters and I was hoping there was a way to solve this issue that I am having.

So if I have

table: example
this is [@colors with red]

table:colors
my color <font color=red>{$1}</font>

This of course works totally fine. However if I run and I get
This is my color red

table: example
this is [@3 colors with red]

table:colors
my color <font color=red>{$1}</font>

It seems the parameter is only passed to the first result. So I only get.
This is my color red
This is my color
This is my color

Is there a way around this?

Comments

  • That may indeed be a bug. To get around it, you can set a variable before the table call, and then use that variable in the sub table.

    {$colortouse==red}[@3 color]
    
    table:color
    my color is {$colortouse}
    

    (I believe the above will work, but I may have the syntax off a bit)

  • Freewolf's original code (I tweaked the line return sightly) actually works for me:

    ; red.ipt
    ; created 10/15/2018 9:39:58 AM
    table: example
    [@3 colors with red]
    
    table:colors
    this is my color <font color=red>{$1}</font>\n
    

    Here's the output:

    If that didn't work, I thought of trying:

    ; red.ipt
    ; created 10/15/2018 9:39:58 AM
    table: example
    [@3 colors with red, red, red]
    
    table:colors
    this is my color <font color=red>{$1}</font>\n
    

    Which also gives the same (good) output. I know this "red" code is just a simplified example of the real issue that may be occurring. But it looks like this sample works on my system.

Leave a Comment