Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Drop Down Not Working

 
Puneet N Vyas
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello JSF Experts ,

I have to make dependent drop down using <h:selectOneMenu> tag,i did this.
i want whenever user picks parent drop down(country in my case),the child drop down should change(States in my case).
).
this use case is working fine using jsf 1.1 api and valuechange listener for jsf components.in addition to that what i want
is whenever user changes parent drop down the first element of child drop down should come as output text.
i tried implementing this use case with the following code.how ever it is not working as per functionality.
Please any one from JSF experts group can give me some pointers,i will be really thankful to experts.

Java Classes RegisterForm (Purpose to get registration form data)


Java enum Country(enum Country to represent country names )



Resource Bundle messages_en_US.properties


and finally UI code(index.jsp) which is having simple form elements



Any Pointers from Experts are welcome.

Thanks,
Puneet Vyas
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18164
53
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
http://www.coderanch.com/t/586042/JSF/java/populate-one-dropdown-options-change

Note that I did not need to bind to the JSF component tree to do this.
 
Puneet N Vyas
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks a lot for your time,i have resolved it using immediate attribute .

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic