6 Replies Latest reply on Jun 6, 2009 10:02 AM by nbelaevski

    SelectItem value and label are similar?

      Hi,

      i'm using RichFaces 3.3.0 and found problem with SelectItem object inside comboBox. The SelectItem takes several parameters and one of each is SelectItem that takes 2 parameters, Object value and String label. In my mind, String label is a value that will appear in comboBox, and Object value is the whole object that represent label in comboBox. but once i try to use this :

      [CODE]

      SelectItem s = new SelectItem("This is the value","This is the label");

      [/CODE]

      The value appear in comboBox is the value of the object (in this case : "This is the value"), not the label value ("This is the label"). Is my logical way wrong? the truth value i want to get is "This is the value" and the label i want to appear is "This is the label"..