Two Laptop Bag
The moose likes JSF and the fly likes refresh page with new data Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JSF
Reply Bookmark "refresh page with new data" Watch "refresh page with new data" New topic
Author

refresh page with new data

Steinboch roicho
Greenhorn

Joined: Mar 01, 2010
Posts: 8
Hi, I have a form that request a name, age and sex;
this data is passed to a backing bean named Person and then is is save in a database;

Then I made and listener that checks if the name(while typing) written in the inputText is all ready in database.
the listener is works, It returns the object Person from db;

but my question is: how do I refresh the bage with the new data, meaning the name, age and sex to be completed with the data taken from db?

I use richfaces, but if you know for jsf or another way please tell me.

thank you
Brendan Healey
Ranch Hand

Joined: May 12, 2009
Posts: 218

You want an autocomplete component, I have experience with the PrimeFaces <p:autoComplete>
component and it works for me. See www.primefaces.orgfor more details. I have no
connection with PrimeFaces other than to be an independent developer.

It seems scary to plumb in a new component library as a new JSF developer but the alternative
(loads of JavaScript, timeouts etc...) is far worse. You'll be pleasantly surprised at how easy it is
to get working.

Regards,
Brendan.
Steinboch roicho
Greenhorn

Joined: Mar 01, 2010
Posts: 8
I don't need an autocomplet, I need my page to be completed with my new data found in db.
And I have to use richfaces, thanks for the site, I didn't know about primefaces.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: refresh page with new data
 
Similar Threads
Object filtering in Hibernate from Database
Servlet/JSP problems
Why do Collections(save Arrays) allow only Objects?
File Operations Program Problem
Validation - Best Practice.