Bookmark Topic Watch 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
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
  • paul wheaton
Sheriffs:
  • Tim Cooke
  • Devaka Cooray
  • Rob Spoor
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
This is a very common error in Struts. Below is a list of possible causes in order of their likelihood:

  • You just plain misspelled the form bean class name. Look very carefully at the type attribute you specified in the <form-bean> stanza in the struts-config.xml file. Is there a misspelling? Are any letters in upper-case that should be in lower-case or visa-versa?
  • You forgot to compile the form bean. Make sure the class file actually exists in the appropriate subdirectory of WEB-INF/classes.
  • Your form bean does not extend org.apache.struts.action.ActionForm. This class must be somewhere in the ancestry of your form bean.
  • You've somehow made it so your form bean has no public constructor with no arguments. Remember, if you added a constructor with arguments, you must also add one without arguments.
  • Check to make sure that the package you've placed your bean in is not "java" or "java.something". Java does not allow you to use this package name for your own classes.




  • Return to Struts1Faq
     
    Look! I laid an egg! Why does it smell like that? Tiny ad, does this smell weird to you?
    a bit of art, as a gift, the permaculture playing cards
    https://gardener-gift.com
      Bookmark Topic Watch Topic
    • New Topic