1 Reply Latest reply on Jan 25, 2008 6:04 AM by Ilya Shaikovsky

    getting selected data from rich:suggestionbox  selected item

    Deb Dutta Novice

      In my application i am using rich:suggestion for autocomplete.
      On selecting of an item from the matched list i want to populate the result value to some out put field. how can can achieve this. i'm very new to rich faces. pls help with the code.

      my design is like that

      <h:inputText id="suggest" ></h:inputText>
       <rich:suggestionbox for="suggest" suggestionAction="#{mybean.autoComplete}" var="result"
       fetchValue="#{result.name}" >
      <h:column >
       <h:outputText value="#{result.name}" ></h:outputText>
       <h:outputText value="#{result.state}" ></h:outputText>
       <h:outputText value="#{result.zip}" ></h:outputText>

      now i can get the matched items on entering the field "suggest".
      when i am selecting a item from the list i want to populate the whole data like result.name,result.state,result.zip
      to other three outputText in the sreen to show the data of the selected item.

      <h:outputText >

      how can i achive this.

      pls help.

      thanks in advance