5 Replies Latest reply on May 17, 2007 2:39 PM by tonylmai

    s:convertEnum usage

      Hello,

      Does anyone know the syntax of s:convertEnum? I'd like to use it but kept having syntax error.

      Thanks.

        • 1. Re: s:convertEnum usage
          bulloncito

          ... it's not on documentation, and exadel studio pro did not autocomplete :S

          • 2. Re: s:convertEnum usage

            Example from seam-pay (in cvs)

            <h:selectOneRadio id="radioList"
             layout="lineDirection"
             value="#{newPayment.paymentFrequency}">
             <s:convertEnum />
             <s:enumItem enumValue="ONCE" label="Only Once" />
             <s:enumItem enumValue="EVERY_MINUTE" label="Every Minute (testing)" />
             <s:enumItem enumValue="HOURLY" label="Every Hour (testing)" />
             <s:enumItem enumValue="DAILY" label="Every Day" />
             <s:enumItem enumValue="WEEKLY" label="Every Week" />
             <ui:remove>
             <f:selectItems value="#{newPayment.frequencies}" />
             </ui:remove>
            </h:selectOneRadio>
            


            and example from seam-ui

            <h:selectOneMenu value="#{person.honorific}">
             <s:selectItems value="#{honorifics}" var="honorific" label="#{honorific.label}" noSelectionLabel="Please select" />
             <s:convertEnum />
            </h:selectOneMenu>
            


            • 3. Re: s:convertEnum usage

              Thanks

              • 4. Re: s:convertEnum usage
                stu2

                btw, you can just grep through the source of the seam examples to answer a question like this for yourself. It isn't always easy to find stuff in the examples by poking around, but searching for example useages is easy with a quick search.

                • 5. Re: s:convertEnum usage

                  Agree. I just downloaded cygwin. Should be able to do grep from now on.