• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • paul wheaton
  • Ron McLeod
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

Creating Drop Down lists in datagrid client component

 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Group,

Question from a newbie to using JSF.

I am currently trying to design a UI for which I am unable to find an example. I was hoping to get your advice on how to create a datagrid client component in which one of the columns is a drop down list.

Steps I followed:

1) Created a simple bean (simpleBean.java) with 2 attributes. (Name [Type:String] and Choice [Type:SelectItem[]])
2) Created an accessor method [public simpleBean[] getArrayofBean()]
3) In the JSP page, I included the bean onto the page/client data sections and tried to associate the attributes of the bean with the datagrid.

I am unable to get a listbox displayed as one of the bean�s attribute in the datagrid. Instead, it displays 4 different text/Boolean columns when I try to include the selectItem[]. I�ve also tried replacing the selectItem[] attribute with the Map and still run into the same problem[i.e. only a limited set of object like String, Integer, boolean etc get accepted].

I'd appreciate any advise/hint on how to get a selectbox into a datagrid client cmoponent. Think I read a post somewhere that a custom component would help. Is that true?

My development Environment: IBM Rational Application Developer.

Thanks for taking the time to read my question,
Aravind
 
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Show us your backing bean and JSP. I am having a hard time visualizing this with the list of properties you described.
 
Aravind Elango
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Gregg,

Thanks for responding. I read through the JSF spec and think I've been toying around with a custom component provided by Rational Application Developer software. I've come to realise that since it is a custom component, it's use is limited.

Thanks,
Aravind
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic