You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Lking <lk...@yahoo.com.br> on 2005/05/05 23:36:36 UTC
DataTable and binding value?
Hello all
I'm trying DataTable and it worked ok if I set "value" and "var" in my
jsf page. But trying to set both in my class having DataTable binded didn't
work. Can anybody help me?
it worked this way...
page...
value="#{bean.array}"
var="myBean"
<h:outputText value="#{myBean.id}"..
but it didn't this way...
dataTable.setValue("#{bean.array}");
dataTable.setVar("myBean");
outputText.setValue("#{myBean.id}");
Thanks.,
Re: DataTable and binding value?
Posted by Lking <lk...@yahoo.com.br>.
Thanks Martin!
----- Original Message -----
From: "Martin Marinschek" <ma...@gmail.com>
To: "MyFaces Discussion" <us...@myfaces.apache.org>
Sent: Friday, May 06, 2005 4:08 AM
Subject: Re: DataTable and binding value?
what you need to do is call "setValueBinding" for the expressions and
prepare a new ValueBinding for that.
like in this sample code:
setValueBinding(new ValueBindingImpl(
FacesContext.getCurrentInstance().getApplication(),
"#{bean.array}");
regards,
Martin
On 5/5/05, Lking <lk...@yahoo.com.br> wrote:
> Hello all
>
> I'm trying DataTable and it worked ok if I set "value" and "var" in my
> jsf page. But trying to set both in my class having DataTable binded
> didn't
> work. Can anybody help me?
>
> it worked this way...
>
> page...
> value="#{bean.array}"
> var="myBean"
>
> <h:outputText value="#{myBean.id}"..
>
> but it didn't this way...
>
> dataTable.setValue("#{bean.array}");
> dataTable.setVar("myBean");
>
> outputText.setValue("#{myBean.id}");
>
> Thanks.,
>
>
Layout and coordinate
Posted by Lking <lk...@yahoo.com.br>.
I was wondering if any of the panels allow me to add components and set
coordinate "x" and "y", just as I can do with swing's layout.
Thanks.
Re: DataTable and binding value?
Posted by Martin Marinschek <ma...@gmail.com>.
what you need to do is call "setValueBinding" for the expressions and
prepare a new ValueBinding for that.
like in this sample code:
setValueBinding(new ValueBindingImpl(
FacesContext.getCurrentInstance().getApplication(),
"#{bean.array}");
regards,
Martin
On 5/5/05, Lking <lk...@yahoo.com.br> wrote:
> Hello all
>
> I'm trying DataTable and it worked ok if I set "value" and "var" in my
> jsf page. But trying to set both in my class having DataTable binded didn't
> work. Can anybody help me?
>
> it worked this way...
>
> page...
> value="#{bean.array}"
> var="myBean"
>
> <h:outputText value="#{myBean.id}"..
>
> but it didn't this way...
>
> dataTable.setValue("#{bean.array}");
> dataTable.setVar("myBean");
>
> outputText.setValue("#{myBean.id}");
>
> Thanks.,
>
>