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

Custom Component Properties

Khaled Mahmoud
Ranch Hand

Joined: Jul 15, 2006
Posts: 361

I tried to develop a Custom Component in JSF. This component is a simple drown list which displays strings in a list in a html select.

Here is the code of the form.

The Custom component is linked to a renderer through custom tag and the list to be displayed is passed as a property from a backing bean.
When the page loads for the first time, the custom tag will pass the list of items to the component and the list will be happily displayed.

But when I click on a command button, the list will be assigned values and a null pointer exception is thrown from the renderer

Attached is my code along with web.xml and tld.
Any idea would be appreciated.

Life is the biggest school
I agree. Here's the link:
subject: Custom Component Properties
It's not a secret anymore!