STRUTS : How to populate a submit button ?!
Hi,
i am wondering why the struts population mechanism does not populate the value attribute of a submit button.
Here's what i have :
An actionForm with an actionToPerform property
An action that initializes the actionToPerform property of the mapped ActionForm (and also a combo from a database) before it forwards the request to the jsp
A jsp that isused to create and update a row in a table of the database. So, in that jsp, there's a <html:submit property="actionToPerform" />
which i had hoped would get its value prepopulated by struts.
Another action that inherits from lookupdispatchaction and that is the target of the html form of the jsp.
if i place a <html:text property="actionToPerform" />
, the text field gets populated . Why doesn't the submit button ?
Is there a better way to use the same jsp for updating and creating rows in a database having the submit button showing 'Add' when in the creation mode, and 'Update' when in the updating mode ?
thanks

