Okay, so I'm not the only one experiencing this. Perhaps it is worth a look at the myfaces source, to see why there is no error message logged when this happens.

John Mani wrote:
Yup, that was it. The lack of any sort of error message didn't help either.
-john

________________________________

From: Jeff Bischoff [mailto:[EMAIL PROTECTED]
Sent: Fri 6/9/2006 2:09 PM
To: MyFaces Discussion
Subject: Re: Weird problem with dataTable, commandButtons, inputText



John,

I might have a clue for you...

When the page is initially displayed, is "selection" equal to null? i.e.
#{backer.selection} would return null. If so then,
#{backer.selection.firstName} will result in a null pointer exception,
which in my experience with myfaces, does not display any kind of error
message but simply causes "weird" behaviour - like buttons not working.

We discussed this a few days ago on [1]

[1] http://www.mail-archive.com/[email protected]/msg22905.html

Regards,

Jeff Bischoff
Kenneth L Kurz & Assoc, Inc.

John Mani wrote:

Hi

I am seeing a weird problem:
I have a page that has a toplevel panelGrid with 2 columns.
 In the left column, I have a panelGroup containing a bunch of
textfields for text entry and
then a commandButton with an associated action
 In the right column, I have a dataTable and a bunch of inputTexts
below the dataTable.

The action for the commandButton in the left panel is called
"backer.search" and
invokes the search method in the backer bean. I'm logging a message in that
search() method, plus this method does a search and sets up the entries
to be displayed
in the dataTable in the right column.

Now, the inputTexts in the right column have values that go like
"backer.selection.firstName"
and so on ... where backer.getSelection() returns a Customer object that
has a getFirstName()
method.

The weird behaviour is that: if the above inputTexts have values like
above : i.e., "backer.selection.firstName"
etc. the commandButton doesn't seem to fire the search() method - the
log message doesn't get
printed and the dataTable is not filled up. However, if the inputTexts
have values like
"backer.firstName" (where backer.getFirstName() is a method that returns
a simple string), the
commandButton does fire the search() method.

I'm at a loss - as these two seem completely independent.

Sorry for the long and rambling mail, but any clues?

-john








Reply via email to