1 Reply Latest reply on May 21, 2011 8:14 AM by Ilya Shaikovsky

    suggestionbox dynamic nothingLabel - is it possible ?

    Val Sw Expert



      I am using rich:suggestionbox component (richfaces 3.3.1.GA, jboss-seam-2.0.2.SP1) .


      "nothingLabel" value is populated if autocomplete list is empty. Is there a way to provide custom message from backing bean.


      for example :

      I am calling web service which returns some list but I want to display custom message as returned from service like "Bad request", "Communication Error" so that it is NOT selectable.

      Is it possible ?


      <h:inputText id="testId" value="#{bean.name}"/>


      <rich:suggestionbox id="suggestionBoxId" for="testId" tokens=","

                          suggestionAction="#{suggestionBean.autocomplete}" var="result"


                          nothingLabel="No name found"

                          frequency="0" minChars="1">


                                    <h:outputText value="#{result.name}" />




      Please suggest.