This exception occurred when I was working on the OA project. I had no answer after searching for it online for a long time. Later, I often asked some online prompts and carefully searched for it, the problem is found. Exception: 01:35:38, 640 error dispatchaction: 260-action [/person] does not contain method named 'addinput' Java. lang. nosuchmethodexception: COM. bjsxt. oa. web. actions. personaction. addinput (Org. apache. struts. action. actionmapping, org. apache. struts. action. actionform, javax. servlet. HTTP. httpservletrequest, javax. servlet. HTTP. httpservletresponse) at java. lang. class. getmethod (class. java: 1581) at Org. apache. str UTS. actions. dispatchaction. getmethod (dispatchaction. java: 347) at Org. apache. struts. actions. dispatchaction. dispatchmethod (dispatchaction. java: 255) at org.apache.struts.actions.dispatchaction.exe cute (dispatchaction. java: 187) at org.springframework.web.struts.delegatingactionproxy.exe cute (delegatingactionproxy. java: 106) at Org. apache. struts. action. requestprocessor. processactionperform (requestprocesso R. java: 431) at Org. apache. struts. action. requestprocessor. process (requestprocessor. java: 236) at Org. apache. struts. action. actionservlet. process (actionservlet. java: 1196) at Org. apache. struts. action. actionservlet. doget (actionservlet. java: 414) at javax. servlet. HTTP. httpservlet. service (httpservlet. java: 690) at javax. servlet. HTTP. httpservlet. service (httpservlet. java: 803) at Org. apache. catalina. core. appli Cationfilterchain. internaldofilter (applicationfilterchain. java: 290) at Org. apache. catalina. core. applicationfilterchain. dofilter (applicationfilterchain. java: 206) at com. bjsxt. oa. web. pagerfilter. dofilter (pagerfilter. java: 29) at Org. apache. catalina. core. applicationfilterchain. internaldofilter (applicationfilterchain. java: 235) at Org. apache. catalina. core. applicationfilterchain. dofilter (applicationfilte Rchain. java: 206) at Org. springframework. orm. hibernate3.support. opensessioninviewfilter. dofilterinternal (opensessioninviewfilter. java: 174) at Org. springframework. web. filter. onceperrequestfilter. dofilter (onceperrequestfilter. java: 77) at Org. apache. catalina. core. applicationfilterchain. internaldofilter (applicationfilterchain. java: 235) at Org. apache. catalina. core. applicationfilterchain. dofilter (applica Tionfilterchain. java: 206) at Org. springframework. web. filter. characterencodingfilter. dofilterinternal (characterencodingfilter. java: 78) at Org. springframework. web. filter. onceperrequestfilter. dofilter (onceperrequestfilter. java: 77) at Org. apache. catalina. core. applicationfilterchain. internaldofilter (applicationfilterchain. java: 235) at Org. apache. catalina. core. applicationfilterchain. dofilter (Application Filterchain. java: 206) at Org. apache. catalina. core. standardwrappervalve. invoke (standardwrappervalve. java: 233) at Org. apache. catalina. core. standardcontextvalve. invoke (standardcontextvalve. java: 175) at Org. apache. catalina. core. standardhostvalve. invoke (standardhostvalve. java: 128) at Org. apache. catalina. valves. errorreportvalve. invoke (errorreportvalve. java: 102) at Org. apache. catalina. core. standardengine Valve. invoke (standardenginevalve. java: 109) at Org. apache. catalina. connector. coyoteadapter. service (coyoteadapter. java: 286) at Org. apache. coyote. http11.http11processor. process (http11processor. java: 844) at Org. apache. coyote. http11.http11protocol $ http11connectionhandler. process (http11protocol. java: 583) at org.apache.tomcat.util.net. jioendpoint $ worker. run (jioendpoint. java: 447) at java. lang. thread. run (T Hread. java: 595) 01:35:38, 703 warn requestprocessor: 528-unhandled exception thrown: Class Java. lang. nosuchmethodexception 1:35:38 Org. apache. catalina. core. serious standardwrappervalve invoke: servlet. service () for servlet action threw exception Java. lang. nosuchmethodexception: action [/person] does not contain specified method (check logs) at Org. apache. struts. actions. dispatchaction. dispatchme Thod (dispatchaction. java: 264) at org.apache.struts.actions.dispatchaction.exe cute (dispatchaction. java: 187) at org.springframework.web.struts.delegatingactionproxy.exe cute (delegatingactionproxy. java: 106) at Org. apache. struts. action. requestprocessor. processactionperform (Code of the problematic requestp class: Package COM. bjsxt. oa. web. actions; import javax. servlet. HTTP. httpservletrequest; import javax. servlet. HTTP. HTTPS Ervletresponse; import Org. apache. commons. beanutils. beanutils; import Org. apache. struts. action. actionform; import Org. apache. struts. action. actionforward; import Org. apache. struts. action. actionmapping; import Org. apache. struts. actions. dispatchaction; import COM. bjsxt. oa. managers. personmanager; import COM. bjsxt. oa. model. person; import COM. bjsxt. oa. web. forms. personactionform; public class personactio N extends dispatchaction {private personmanager; @ override protected actionforward unspecified (actionmapping mapping, actionform form, httpservletrequest request, httpservletresponse response) throws exception {request. setattribute ("PM", personmanager. searchpersons (); Return Mapping. findforward ("Index");} // open the Add interface protected actionforward addinput (actionmapping mapping, actionform Form, httpservletrequest request, httpservletresponse response) throws exception {Return Mapping. findforward ("add_input");} // Add public actionforward add (actionmapping mapping, actionform form, httpservletrequest request, httpservletresponse response) throws exception {personactionform PAF = (personactionform) form; int orgid = PAF. getorgid (); person P = new person (); beanutils. copyproperties (P, PAF); personmanager. addperson (p, orgid); Return Mapping. findforward ("pub_add_success");} public actionforward del (actionmapping mapping, actionform form, httpservletrequest request, httpservletresponse response) throws exception {personactionform PAF = (personactionform) form; personmanager. delperson (PAF. GETID (); Return Mapping. findforward ("pub_del_success");} public void setpersonmanager (P Ersonmanager personmanager) {This. personmanager = personmanager;} class clearly contains the addinput method, but it always reports an error during running that this method is not available in this class. Later, it was discovered that the addinput was originally set with protected, so the JSP page could not be accessed, so an error was reported. Change protected to public, and the problem was solved.