Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Setting the readOnly attribut to h:inputText component when a page loads.

843842Jun 24 2005 — edited Jun 26 2005
Hi,

I am new to this JSF technology and am a little confused at times. However, I am getting to grips with it.

That said, I am a little lost/confused with how to set an inputTest's readOnly attribute when a page loads.

I want to read a sessionScope and store the value in a String variable. If this equals "yes" (for example), then the inputText's readOnly attribute needs to be set to 'false'. Else it is true.

Is there a way I can do this? I have tried putting the code into the postRender, preRender and rendered attributes of the hx:scriptCollector tag, but this doesn't work (as the components have not been created on my page).

Can anyone help me with this, or point me in the right direction?!

Thanks

BB.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 24 2005
Added on Jun 24 2005
8 comments
475 views