1. setProperty in jsp does not have any effect if the value is empty string.  
2. you use scope session

So when set A it stores it in the session bean, next time when you set B with no 
A, B gets set in the bean and A remains the same (session scope).

hth
*********************************************************************
* Boris Niyazov                Ph:  212-854-4094  Fax: 212-854-1749 *
* Systems Manager              Email: [EMAIL PROTECTED]             * 
* Columbia Law School          URL: http://www.law.columbia.edu     *
*********************************************************************                  
             

>
>This question may be asked out of ignorance, but it seems to me that using
>the tag:
>
><jsp:useBean id="MyBean" scope="session" class="Test.MyBean" />
><jsp:setProperty name="MyBean" property="*" />
>
>to assign values from form fields to the bean is of limited use.
>
>Let's assume that there are 2 text fields, A and B on Jsp1.jsp, with B
>being required.  I have some code that checks to make sure B is populated,
>if it's not, the browser returns to Jsp1.jsp.
>
>The problem I run into is that I can populate A with a value, submit the
>form, get returned to Jsp1.jsp, delete A and populate B, submit the form,
>and continue.  I how have values for both A and B, even though A was blank.
>
>I suspect that I'm not the first person to ask this question, is there an
>obvious solution that I missed, if not, what do other people do to get
>around this problem; do all of the assignements by hand?
>
>Thanks.
>
>
>--
>
>NOTICE:  The information contained in this electronic mail transmission is
>intended by Convergys Corporation for the use of the named individual or
>entity to which it is directed and may contain information that is
>privileged or otherwise confidential.  If you have received this electronic
>mail transmission in error, please delete it from your system without
>copying or forwarding it, and notify the sender of the error by reply email
>or by telephone (collect), so that the sender's address records can be
>corrected.
>

Reply via email to