File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSF and the fly likes not changing backing Bean Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "not changing backing Bean" Watch "not changing backing Bean" New topic

not changing backing Bean

Javoso Torso
Ranch Hand

Joined: Aug 15, 2003
Posts: 88

I have a dropDown box (selectOneMenu) which by change submit the form (JavaScript) and has a valueChangeListener.

The ActionClass changes a couple of backing Beans according to the value of ValueChangeEvent.getNewValue.

My problem is that one of those Backing Beans is not changing, so: keeping the old values. Even after reiterated dropDown selections.

If I printout the values of the Bean in the action class (to debug) the values are changing! But not in the front end...

I tried changing the scope of the Bean in the faces-config, was session I changed it to request, but it didn�t help.

I even tried with an immediate="true" in the selectOneMenu...

Any ideas where the problem can be?

Thanks + regards,
[ February 02, 2005: Message edited by: Javoso Torso ]

I hate 'trial and error'<br />and I am doing it all the time
Kerry Wilson
Ranch Hand

Joined: Oct 29, 2003
Posts: 254
you should post code samples...
SCJP 1.4
Javoso Torso
Ranch Hand

Joined: Aug 15, 2003
Posts: 88

[please ignore onkkeyup (it is onkeyup in the real code)]

theActions, changeYear method :

I know it is a bit strange, I am using an action in an action. I didn�s see the need to recode the same procedure if I already had it in the moveWeek method.

Weird is, that othe beans which have being changed in that method (moveWeek) do change in the front end... so why not backBean...
[ February 08, 2005: Message edited by: Javoso Torso ]
Javoso Torso
Ranch Hand

Joined: Aug 15, 2003
Posts: 88

I am coming closer to a solution...

The problem is somehow in the translation from the backing bean to the tag.

The funniest is that if I use an "h:inputText" the content doesn�t change (the problem)
if I use an "h: outputText" the content changes !!!

Any ideas?

[ March 01, 2005: Message edited by: Javoso Torso ]
I agree. Here's the link:
subject: not changing backing Bean
It's not a secret anymore!