I have the following code snippet:
bean:define id=vendornames name=ProdAddForm
property=vname
type=java.util.Collection/
then below
html:select property=vname
html:options collection=vendornames
property=value labelProperty=label/
/html:select
I have a getter method in my
to be selected. You've
accounted for the latter.
You need another method to account for the former.
The property
referred to in your bean:define (returning a
Collection) should not be
the same property referred to in your html:select
that returns a
String.
-- Jim
josef richberg [EMAIL
Collection getVnameList(){
return new DBAccess().getVendorNames();
}
public void setVname(String value){
xx
}
public String getVname(){
xx
}
Then change your bean:define property to
vnameList. That should
do the trick.
-- Jim
josef richberg [EMAIL PROTECTED] writes
().getVendorNames();
}
public void setVname(String value){
xx
}
public String getVname(){
xx
}
Then change your bean:define property to
vnameList. That should
do the trick.
-- Jim
josef richberg [EMAIL PROTECTED] writes:
That I understand. What I don't understand is how
to
do
4 matches
Mail list logo