Hi,
In my code I have a
jsp page, with text fields, buttons and a list box, myDetails.jsp, the information entered here is all
read/verified in ProcessMyDetailsAction.java. (I am also using
Struts)
If the list box is populated, I want one of the text fields to be grayed out.(disabled or readonly)
(ie, after the first batch on info is entered, the details are displayed in the list box and the fields are empty, so more information can be entered, but I want the date textfield to be disabled, as I don't want to allow the user to change the date.)
I have a boolean variable set up in my
java code, which is set to true if the list box is not empty,
and I am trying to read it on the jsp page to set the text field disabled property to true or false
here is the code i am using:
myDetails.jsp
<html:text name="myDetailsActionForm" maxlength="3" size="3" property="myDetails.textBox" styleId="TxBox" dsabled="#{ProcessMyDetailsAction.listBoxPopulated}" />
ProcessMyDetailsAction. is my Java class and
listBoxPopulated is my boolean variable, which gets set to true.
If anyone has any suggestions, I would be greatful..