Simplica

ProductsLearnPurchaseSupportDemoDownload
  [Search] Search   [Recent Topics] Recent Topics  
dynamically loading e:select
Forum Index -> General
Author Message
cobar


Joined: 08/01/2007 17:02:58
Messages: 98
Offline

I have 3 e:selects. One for month one for year. The third select is the number of weeks in the selected month/year. I was hoping to use the e:select component to dynamically set week select component. However, the weekSelect.setItems(SelectItem[]) does not render the SelectItems, weekSelect.addItem also does not work as anticipated. I was also supprised that you can not use <f:selectItems> only <f:selectItem>.
 Filename TestManagedBean.java [Disk] Download
 Description
 Filesize 7 Kbytes
 Downloaded:  562 time(s)

 Filename calTest.jsp [Disk] Download
 Description testBean com.ec.TestManagedBean session
 Filesize 3 Kbytes
 Downloaded:  642 time(s)

cobar


Joined: 08/01/2007 17:02:58
Messages: 98
Offline

Please disregard. Going through the API doc I realized you need to bind a dataModel which contains the List<SelectItem>. Only thing I have not figured out is what the onchange tag attribute is all about.
adina_mihai
Simplica Team

Joined: 04/01/2007 00:00:00
Messages: 189
Offline

Onchange event is fired when the value from e:select has been changed by user.
cobar


Joined: 08/01/2007 17:02:58
Messages: 98
Offline

So if I understand you onchange="true" means you can implement public void onchange(ActionEvent ae) in the managed bean or is it a value change event.
adina_mihai
Simplica Team

Joined: 04/01/2007 00:00:00
Messages: 189
Offline

If you set onchange="#{managedBean.componentChange}", then you can implement public void componentChange(ActionEvent e) in your backing bean.
 
Forum Index -> General
Go to:   
Powered by JForum 2.1.7 © JForum Team
Home   |  News   |  Contact   |  About   |  License   |  Privacy   |  Documentation
Copyright © 2009 Simplica Corporation. All rights reserved.