Win a copy of Head First Android this week in the Android forum!
  • 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 Clapham
  • Ron McLeod
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Jesse Silverman
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Al Hobbs
  • salvin francis

How to populate a form from a tree node

 
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a JSF screen (jsp/jsf file) that is made up of a tree and four forms. The tree is always rendered (visible) while Only one form is rendered at a time. So the tree and anyone of the forms is visible at any point in time.
The tree node that is clicked determines which form is rendered. When a node of the tree is clicked, a method is called from the backing bean of the tree. The methodis suppoded to both render the tree and the form, and populate the form with data.

Problem
=======
The each form gets rendered, but they are never populated with data. I know the form and methods are functioning well, because when I call the action methods from a value bound button that is attached to the form, the form gets populated with data. i.e. each form works very well (gets populated with data) when the method is called from a button attached to the form, but not when the method is called via a tree node and the tree's backing method.

Help
====
Please tell me how to populate the fields of the form when it is sharing a screen with the tree. Please note, the clicking of a node of the tree is the trigger.

To put my question another way, if two forms appear in the same screen (JSP/JSF file) say forms A and B, can a button on form A, populate the fields of form B via JSF lifecycle? The answer to this will enable me to work out how the tree/form case can be made to work.

Please note, although the tree and the forms are in the same screen each form has a separate backing bean.

Thanks
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic