Hi,

I think I have a poor understanding regarding form beans...

I have a problem concerning reset method and forwarding to the same form. I have a 
link in a submenue like 
<html:link page="/editTable.do?table=sometable" target="page">
to make the method as generic as possible. The request parameter determines what table 
I use for to edit the values.

There is a formbean, an Actionforward method and a mask with a hidden fiels which 
determines what I want to do. I ommit the reset method because I don't want to reset 
the values (at least for the instance variable "callid" which should hold the table 
name) and  I don't want to use session scope, only request scope. 

When called the first time I retrieve the correct parameter 
request.getParameter("table") and store it in another hidden field (callid). When 
table!=null I know it is called from the menue, so I build a table "select id,txt,opt 
from table" as parameter for a selection list.

When table==null I  look for a hidden field. When it is "select" the method looks for 
the data set for the id. When the field holds "submit" the method looks for input 
field "insert","delete" or "edit" and do the right thing. ActionFordward always 
forwards to the same table "tablemask.jsp".
  <form-beans>
    <form-bean name="tableForm"
               type="com.textilveredlung.formbean.TableForm"/>
  </form-beans>

<!-- ========== Action Mapping ======= -->
  <action-mappings>
    <!-- edit Table to populate form sheet -->
    <action    path="/editTable"
               type="com.textilveredlung.general.editTableAction"
               name="tableForm"
               scope="request"
               input="/txdb/masken/base/tablemask.jsp"
               validate="false">
      <forward name="success" path="/txdb/masken/base/tablemask.jsp" redirect="false"/>
    </action>

BUT: the field are always set to null, so the dbtable field "callid" although set by 
((TableForm)form).setCallid(table). I ommit the reset method in TableForm - nothing 
helps. What do I do wrong?

Best regards and many thanks for help

Thomas


>:-) As sceptical as one can be! (-:<



----------
Get a fun email address at http://another.com
COOL: Personalise a t-shirt with your name/email/slogan 
from 9.99 pounds. CLICK HERE http://another-shop.com
--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to