Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

font color in a drop-down list

Nortel22
Level 2
Level 2

I have two item values - I would like the first (1) value font color in black and the second (2) value color in red. How do I go about accomplishing this?

3 Replies
Nortel22
Level 2
Level 2

if ($.boundItem(xfa.event.newText) == "2") {

  if (xfa.host.version < 😎 {

    this.resolveNode("$").fontColor = "255, 0, 0";

  }

  else {

    var CaptionColorBackup = this.resolveNode("$").caption.font.fill.color.value;  

    this.resolveNode("$").font.fill.color.value = "255, 0, 0";

    this.resolveNode("$").caption.font.fill.color.value = CaptionColorBackup;

  }

}

This is what I have so far, but the entire field is red. What do I need to do in order to get just second value text to appear in red?

radzmar
Level 10
Level 10

Hi,

don't waste your time, you cannot color the items individual.