2 Replies Latest reply on Jan 26, 2014 1:09 AM by probed total sectors

    How to get a combobox value name, not the export name

    probed total sectors Level 1

      I want to copy the item name from a combo list and display the selection in another field text, but I just got the export value and not the value name, any ideas? Thanks for your attention.

      I have created this combo box in a document JavaScript:

      var l = this.getField("BrandList");
      .setItems([["ITEM LIST"],["ITEM 1","B010"],["ITEM 2","B020"],["ITEM 3","B030"],["ITEM 4","B040"],[" "]]);
      .readonly = false;
      .defaultValue = [ITEM LIST"];
      l.editable = false;

      Now, I want to display the slected item name ("ITEM 1", "ITEM 2", etc) in another field, I have tried this code in the text field properties>Calculate, where I want the Item name appears, but I got the Export Value, e.g. "B010", "B020", etc.

      getField("NewField").value = getField("BrandList").valueAsString;