you can use the <f:param> tag to pass a parameter in jsf.
although I havent tried it in jsf, but i use it in jboss-seam. I think it
will work.
Lisa wrote:
>
> I want to build a SelectItem list by calling a method in my backing bean,
> but I want to be able to pass the backing bean a String (from the XHTML).
>
>
> ---
> This is what I currently have:
>
> <h:selectOneListbox
> rendered="#{carBean.listMode}"
> id="idSelectVehicleType"
> value="#{carBean.vehicleType}"
> size="1">
>
> <f:selectItems id="idCarBeanTypeList"
> value="#{carBean.vehicleTypeList}"/>
> </h:selectOneListbox>
>
> where vehicleTypeList is a method in CarBean.getVehicleTypeList()
>
> ---
> So I want to change the method signature to accept a String like so:
>
> CarBean.getVehicleTypeList(String s)
>
> and in the XHTML pass String s to CarBean.getVehicleTypeList(String s).
>
> Is this possible?
> value="#{carBean.vehicleTypeList("myString")}"
>
>
> thanks
>
>
> Lisa
>
--
View this message in context:
http://www.nabble.com/selectList---how-to-pass-a-parameter-to-backing-bean-method-from-XHTML--tf3218841.html#a8945328
Sent from the MyFaces - Users mailing list archive at Nabble.com.