As Joe Germuska advised, it is more conventional to to have two different Actions mappings. set validation=false in one and use it for the displaying the JSP the first time. Use the other Actions mappings (with validation set to true) for subsequent displays of the JSP.
Ola. the --- Bryce Fischer <[EMAIL PROTECTED]> wrote: > This is similar to the issue I had last night. What > was suggested to me, > and it worked, was to turn automatic validation off > by specifying > validate=false in the action mapping, and manually > validating in my > DispatchAction. > > PC Leung wrote: > > >The web page displays at the first time with the > following error. > > > >java.lang.NullPointerException > > > java.text.SimpleDateFormat.parse(SimpleDateFormat.java:1108) > > java.text.DateFormat.parse(DateFormat.java:333) > > > com.erp.quotation.AddUserProfileForm.getSqlJoinDate(AddUserProfileForm.java:68) > > > com.erp.quotation.AddUserProfileForm.validate(AddUserProfileForm.java:80) > > > org.apache.struts.action.RequestProcessor.processValidate(RequestProcessor.java:942) > > > > > >When it first displays, I want it to show with a > token. > >Then I make a setup DispatchAction like the > following. > > > >public final class AddUserProfileAction extends > DispatchAction { > > public ActionForward setup (ActionMapping > mapping, > > ActionForm form, > > HttpServletRequest request, > > HttpServletResponse response) > > throws Exception { > > saveToken(request); > > return mapping.findForward("success"); > > } > > > >How it get a validation error message? > >Actually submit button has not been clicked. > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > ___________________________________________________________ALL-NEW Yahoo! Messenger - all new features - even more fun! http://uk.messenger.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]