File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSF and the fly likes Enabling and disabling Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Enabling and disabling" Watch "Enabling and disabling" New topic

Enabling and disabling

Zein Nunna
Ranch Hand

Joined: Mar 31, 2005
Posts: 245
Hi guys,

I have quite a trivial problem which i cant seem to solve.

I want to enable/disable a set of buttons onclick (done via JavaScript). This is my code

This doesn't seem to work!

A similar issue I have is with 'readOnly'

The JavaScript when button above clicks is

The box 'flashes' (to readOnly = false) momentarily and then resorts back to the original readOnly=true.

Any ideas, thoughts, tips or tutorials?
Thanks for your thoughts,
Richard Green
Ranch Hand

Joined: Aug 25, 2005
Posts: 536
<h:commandButton value="blah" immediate="true" disabled="#{yourBackingBean.someProperty}" />

MCSD, SCJP, SCWCD, SCBCD, SCJD (in progress - URLybird 1.2.1)
wood burning stoves
subject: Enabling and disabling