• Post Reply Bookmark Topic Watch Topic
  • New Topic

Populating data in h:selectOneMenu from Database  RSS feed

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends,

In my JSF program, I want to populate data from MS-Access database to <h:selectOneMenu> combobox. I created an ArrayList to return the data to combobox. But I am getting conversion error. Kindly help me on this issue. Please send me if you have any sample coding to acheive this one. Thanks in advance.

Regards
Ragavan
 
Ranch Hand
Posts: 114
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are they SelectItem objects in the ArrayList?
 
Ragavendran Srinivasan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ya I added the selectItems. But it still showing the error. Do you have any sample coding for that? If so kindly send me......

Thanks
Ragavan
 
A. Dusi
Ranch Hand
Posts: 114
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is the value you are mapping in the backing bean a String?


The choice property in myBean must be a String.
[ February 06, 2008: Message edited by: A. Dusi ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!