Showing nothing instead the %f in case another variable is empty

joanm
2022-05-18
2022-05-19
  • joanm - 2022-05-18

    Hello all,

    I have a series of rectangles emulating a table control. 6 columns x 6 rows.
    Odd rows are white background and even rows are grey (mimicking a table too).

    This said, this gets populated automatically, and the first column has the name of the item and the other columns have the values related to that item.

    Sometimes not all the rows are filled and the item name (first column) is an empty string ('') which looks like an empty cell.
    But all the other columns show "0.00000":

    Name Value 1 Value 2
    OneName 1.2345 1.2345
    0.00000 0.00000

    In this case, I'd like to show another empty cell instead of the "0.00000":

    Name Value 1 Value 2
    OneName 1.2345 1.2345

    ^ notice the empty row (what I'd like to get).

    I can only think of hiding the rectangle and showing another rectangle that's empty to simulate an empty cell, but... is there any better way you can hint me to use?

    As always, thank you very much in advance.

     

    Last edit: joanm 2022-05-18
  • joanm - 2022-05-19

    Found the better way: just use the condition to multiply the font color and if the text is '' then I can BOOL_TO_INT the condition (1) and * it for the transparent font color + BOOL_TO_INT (0) the <> '' condition to * it for the black font color without transparency.

    :)

     
    πŸ‘
    1

Log in to post a comment.