0 Replies Latest reply on Oct 27, 2009 12:27 PM by tom.lorenz

    Suggestionbox and Hotkey on enter

    tom.lorenz

      How can i prevent the Hotkey to be fired when the selects a value from the suggestionlist with hitting enter in the following example ?

      <rich:hotKey selector="#searchclazz" key="return" handler="#{rich:element('startSearchButton')}.onclick();return false;"/>
      <h:inputText id="searchclazz" value="#{TAOverview.searchclazz}" />
      <rich:suggestionbox usingSuggestObjects="true" width="200" height="200" status="none"
       suggestionAction="#{TAOverview.autocompleteSearchKlasse}" var="klasse" for="searchclazz"
       id="suggest_searchclazz" tokens="," ajaxSingle="true">
       <h:column>
       <h:outputText value="#{klasse}" />
       </h:column>
      </rich:suggestionbox>


      I tried the following:
      oncomplete="return false;"
      oncomplete="Event.stop(event);"

      Are there any other solutions ?
      I am using Richfaces 3.3.2SR1 with MyFaces 1.2.5!