2 Replies Latest reply on Jan 17, 2008 10:48 AM by Pete Muir

    How to  switch to the tab page where the error occurs in tab

    ken guong Newbie

      Hi,
      I use a <rich:tabPanel switchType="Ajax">
      It contains 3 tabs, tabA,tabB,tabC.

      In each tab, user must fill in some text in the h:inputText.
      All these inputText are set to:
      required="true"

      And
      <h:commandButton id="save" type="submit" value="Save" action="#{mybean.save()}"/> are used to submit the form.

      If I didn't fill in all the required text in tabA, when the form is submited.
      The focus is on tabA. It is OK.

      However, if I filled in all the required text in tabA, when the form is submited.
      The focus is still on tabA.
      I want the tabs swtiched to tabB, since I didn't fill in text in tabB.

      Anybody can help?
      Thanks!