• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

ActionDispatcher and Validation

 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using ActionDispatcher and EventActionDispatcher for my Action classes. For whatever reason, when I do this, the form is trying to be validated the initial time the JSP is being rendered. Because of this, it goes into a validation loop and throws a StackOverflow. If anyone knows why this is happening, it would be much appreciated.

Thanks. Here is the code.

AddUserAction.java


struts-config
 
Ranch Hand
Posts: 181
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are you initially calling /AddUser.do? If so, it is performing validation because validate is set to true. I don't use dispatcher that often, but I think you would want one action to load the page (with validate="false") and use the dispatcher for the submittal (add, edit, etc..) and validate="true".
 
Henry Lowell
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Tha's what I've done to get past the issue. I am assuming this is the only way if using auto validation?
 
Can you shoot lasers out of your eyes? Don't look at this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic