AnsweredAssumed Answered

Please help !!! Add a field into the body of layout, the script doesn't work.

Question asked by RichardVu on Mar 24, 2016
Latest reply on Mar 28, 2016 by RichardVu

layout FM.JPGBrowse mode.JPG

Here script :

Set Variable [$A; Value: Get(ActiveFieldContents)]

if [$A = " Must" or " PUP"]

Insert Calculated Result [Select;TextStyleAdd(TextColor($A;RGB(50;150;0));Bold)]

Elseif [$A = " Wait" ]

Insert Calculated Result [Select;TextStyleAdd(TextColor($A;RGB(200;50;0));Bold)]

Elseif [$A = " UNPUP" ]

Insert Calculated Result [Select;TextStyleAdd(TextColor($A;RGB(225;180;0));Bold)]

it works perfectly.

 

Now, I add one more Field into the layout. It doesn't work.

it will work if I do manual select  the text-field and choose color ( any color) it will pick the right color which is assigned in the script.

So I think when I add the field into layout, It doesn't go to Textcolor on script until I select color. Adding one field could break some points in the script or layout. I have no idea for that.

Thanks for help

Outcomes