Drop-Down List - Cannot Retrieve Definition From Form Bean Null
My drop-down list got an error message: org.apache.jasper.JasperException: Cannot retrieve definition for form bean null I have tried to display the drop-down list in two ways: First: html:select size=1 property=editor multiple=false html:options collection=editors property=name labelProperty=name/ /html:select Second: bean:define id=editorsList name=editors scope=session / html:select property=editor size=1 multiple=false html:options collection=editorsList labelProperty=name property=value/ /html:select The editors is a Collection of EditorBean passed to the JSP this way: HttpSession session = request.getSession(); session.setAttribute( editors, editors ); and Editor Bean is: public class EditorBean { private String name; public EditorBean() {} public EditorBean( String name ) { this.name = name; } public String getName() { return name; } public void setName( String name ) { this.name = name; } } __ Do you Yahoo!? Free Pop-Up Blocker - Get it now http://companion.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Drop-Down List - Cannot Retrieve Definition From Form Bean Null
Hi Caroline, The list should not be a session attribute. Instead, you should declare member variables inside your Form bean as follows.. public class EditorForm { String [] options; EditorBean editor; public String [] getOptions() { return options; } public EditorBean getEditor() { return this.editor; } } In your JSP page, html:select property=editor html:options property=options / /html:select Hope this helps you... Ajay My drop-down list got an error message: org.apache.jasper.JasperException: Cannot retrieve definition for form bean null I have tried to display the drop-down list in two ways: First: html:select size=1 property=editor multiple=false html:options collection=editors property=name labelProperty=name/ /html:select Second: bean:define id=editorsList name=editors scope=session / html:select property=editor size=1 multiple=false html:options collection=editorsList labelProperty=name property=value/ /html:select The editors is a Collection of EditorBean passed to the JSP this way: HttpSession session = request.getSession(); session.setAttribute( editors, editors ); and Editor Bean is: public class EditorBean { private String name; public EditorBean() {} public EditorBean( String name ) { this.name = name; } public String getName() { return name; } public void setName( String name ) { this.name = name; } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
hi! i have defined a form KioskForm, that i am using later in the application. since my current form consists only of a submit button and no fields, html:form action=/kiosk browse kiosks html:submit value=Submit//html:form can i define kioskForm in the action mapping as the form for this empty form? what i am trying to do is just test struts forms on my server. i have been having problems with it not matching my requests to the appropriate action class. thanks cheers ajay From: Max Cooper [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Cannot retrieve definition for form bean null Date: Tue, 7 Oct 2003 22:33:54 -0700 Struts is looking for the action form defined for the /kiosk action (since that is what the html:form submits to on your page. The action or action form does not exist, so you get the error of Struts looking for the null action form. Use a regular HTML form tag to evade that issue, or define the stuff for your /kiosk action. -Max - Original Message - From: ajay brar [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 07, 2003 9:30 PM Subject: Cannot retrieve definition for form bean null hi! i had heard that a form bean for a form was optional, not sure why i am getting this error here. i have a button on a page and it goes like html:form action=/kiosk browse kiosks html:submit value=Submit//html:form in my struts-config.xml i have defined the following action mapping action path=/kiosk type=KioskAction scope=request forward name=successpath=/kiosk.jsp / /action could someone please help with this error. thanks cheers ajay _ Chat via SMS. Simply send 'CHAT' to 1889918. More info at http://ninemsn.com.au/mobilemania/MoChat.asp?blipid=6800 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Get less junk mail with ninemsn Premium. Click here http://ninemsn.com.au/premium/landing.asp - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cannot retrieve definition for form bean null
Hallo, I am looking for mistake and not to see it. I have jsp: %@ taglib uri=/tags/struts-html prefix=html % html:form action=/SaveMenuLang method=post focus=adminMenuLang html:hidden name=adminMenuLang property=langId / html:hidden name=adminMenuLang property=packId / ... /html:form , in my struts-config is: form-bean name=adminMenuLang type=org.apache.struts.action.DynaActionForm form-property name=langId type=java.lang.Integer / form-property name=packId type=java.lang.Integer / form-property name=menuId type=java.lang.Integer / form-property name=menu type=java.lang.String / /form-bean and action path=/PrepareLangMenu name=adminMenuLang scope=request type=cz.chalu.struts.modules.admin.PrepareLangMenuAction forward name=success path=.main.admin.menu.lang / forward name=error path=.main.admin.menu.lang / /action action path=/SaveMenuLang name=adminMenuLang scope=request type=cz.chalu.struts.modules.admin.SaveLangMenuAction forward name=success path=.main.admin.base / forward name=error path=.main.admin.menu.lang / /action in action cotroler: System.out.println(begin ...); LanguageMenusBO bo = new LanguageMenusBO(); LangMenuDTO dto = new LangMenuDTO(); DynaActionForm theForm = (DynaActionForm) form; BeanUtils.copyProperties(dto, theForm ); BeanUtils.copyProperties(theForm, bo.getLangMenu(dto)); request.setAttribute(mapping.getAttribute(), theForm); //request.setAttribute(adminMenuLang, theForm); System.out.println(finish controler ...); return (mapping.findForward(Config.SUCCESS)); and I got exception ... 22:58:26,005 INFO [STDOUT] finish controler ... 22:58:27,603 ERROR [Engine] ApplicationDispatcher[/cms] Servlet.service() for servlet jsp threw exception org.apache.jasper.JasperException: Cannot retrieve definition for form bean null at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:254) Does anybody see what I am not? I looking at this too long and do not see anything :( when I delete form tags html:form ... and /html:form and leave body of form, this message I do not get and hidden inputs are filled correctly as all others. Thanks, Jiri - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cannot retrieve definition for form bean null
Hi, I got the above error when I ran my struts app. I am not using a form for this action since I only need to diaply it. And I am using Tiles framework for this. Appreciate any help. __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
Is it absolutely necessary to use a form bean for every action? I will only let user to click on a link and forward it to another page while sending a value. Should I define a form bean for this? And how can I do it? regards, --- victor gusz [EMAIL PROTECTED] wrote: Hi, I got the above error when I ran my struts app. I am not using a form for this action since I only need to diaply it. And I am using Tiles framework for this. Appreciate any help. __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cannot retrieve definition for form bean null
hi! i had heard that a form bean for a form was optional, not sure why i am getting this error here. i have a button on a page and it goes like html:form action=/kiosk browse kiosks html:submit value=Submit//html:form in my struts-config.xml i have defined the following action mapping action path=/kiosk type=KioskAction scope=request forward name=successpath=/kiosk.jsp / /action could someone please help with this error. thanks cheers ajay _ Chat via SMS. Simply send 'CHAT' to 1889918. More info at http://ninemsn.com.au/mobilemania/MoChat.asp?blipid=6800 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
If you don't define a form in the struts config file how can you expect the form tag to work correctly? It's whole purpose is to reference the form attribute in your config and then reference the corresponding form in the request. Use the standard html form tag when you don't define a form for your action (form). On Tue, 2003-10-07 at 23:30, ajay brar wrote: hi! i had heard that a form bean for a form was optional, not sure why i am getting this error here. i have a button on a page and it goes like html:form action=/kiosk browse kiosks html:submit value=Submit//html:form in my struts-config.xml i have defined the following action mapping action path=/kiosk type=KioskAction scope=request forward name=successpath=/kiosk.jsp / /action could someone please help with this error. thanks cheers ajay _ Chat via SMS. Simply send 'CHAT' to 1889918. More info at http://ninemsn.com.au/mobilemania/MoChat.asp?blipid=6800 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
Struts is looking for the action form defined for the /kiosk action (since that is what the html:form submits to on your page. The action or action form does not exist, so you get the error of Struts looking for the null action form. Use a regular HTML form tag to evade that issue, or define the stuff for your /kiosk action. -Max - Original Message - From: ajay brar [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 07, 2003 9:30 PM Subject: Cannot retrieve definition for form bean null hi! i had heard that a form bean for a form was optional, not sure why i am getting this error here. i have a button on a page and it goes like html:form action=/kiosk browse kiosks html:submit value=Submit//html:form in my struts-config.xml i have defined the following action mapping action path=/kiosk type=KioskAction scope=request forward name=successpath=/kiosk.jsp / /action could someone please help with this error. thanks cheers ajay _ Chat via SMS. Simply send 'CHAT' to 1889918. More info at http://ninemsn.com.au/mobilemania/MoChat.asp?blipid=6800 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
form bean null
what does this error mean? cannot retrieve definiton for form bean null -- Frances Aleah Z. De Guzman SA/Programmer Ingenium Technology, Inc. http://www.ingenium.com.ph Disclaimer : This message is intended only for the named recipient. If you are not the intended recipient you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: form bean null
Is the name attribute missing in say bean:write tags? Name shud be form bean name. Please check that. Thanks. -Vinay -Original Message- From: Frances Aleah Z. de Guzman [mailto:[EMAIL PROTECTED] Sent: Thursday, May 29, 2003 7:28 AM To: Struts Users Mailing List Subject: form bean null what does this error mean? cannot retrieve definiton for form bean null -- Frances Aleah Z. De Guzman SA/Programmer Ingenium Technology, Inc. http://www.ingenium.com.ph Disclaimer : This message is intended only for the named recipient. If you are not the intended recipient you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited. --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.484 / Virus Database: 282 - Release Date: 5/27/2003 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.484 / Virus Database: 282 - Release Date: 5/27/2003 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cannot retrieve definition for form bean null - Whats the deal?
I have the following code in my struts config: ... form-bean name=jumpCenterForm type=form.JumpCenterForm / ... ... action path=/viewJumpCenter type=action.ViewJumpCenterAction scope=request name=jumpCenterForm validate=false input=screen.jumpCenter forward name=form path=screen.jumpCenter redirect=false / /action ... ... html:form action=insertUser method=POST ... /html:form ... When the action viewJumpCenter is called, I receive the following error: [ServletException in:/WEB-INF/jsp/jumpCenter.jsp] Cannot retrieve definition for form bean null' What is happening here? I have several other forms setup like this that do not require me to specify the type of form bean in the html:form tag. What else could be causing this error? I put debug statements in the form and action constructors, they are being created fine. Any Ideas? Regards, Joshua This communication, including attachments, is for the exclusive use of addressee and may contain proprietary, confidential or privileged information. If you are not the intended recipient, any use, copying, disclosure, dissemination or distribution is strictly prohibited. If you are not the intended recipient, please notify the sender immediately by return email and delete this communication and destroy all copies. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null - Whats the deal?
I think you don't have defined an action-mapping for path insertUser. html:form looks for the form-bean name in mappings that comes with the path that is set by action attribute. It find nothing so null is the name of the current bean that it is looking for, and you get this exception. Nico. I have the following code in my struts config: ... form-bean name=jumpCenterForm type=form.JumpCenterForm / ... ... action path=/viewJumpCenter type=action.ViewJumpCenterAction scope=request name=jumpCenterForm validate=false input=screen.jumpCenter forward name=form path=screen.jumpCenter redirect=false / /action ... ... html:form action=insertUser method=POST ... /html:form ... When the action viewJumpCenter is called, I receive the following error: [ServletException in:/WEB-INF/jsp/jumpCenter.jsp] Cannot retrieve definition for form bean null' What is happening here? I have several other forms setup like this that do not require me to specify the type of form bean in the html:form tag. What else could be causing this error? I put debug statements in the form and action constructors, they are being created fine. Any Ideas? Regards, Joshua This communication, including attachments, is for the exclusive use of addressee and may contain proprietary, confidential or privileged information. If you are not the intended recipient, any use, copying, disclosure, dissemination or distribution is strictly prohibited. If you are not the intended recipient, please notify the sender immediately by return email and delete this communication and destroy all copies. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null - Whats the deal?
Any chance of a typo in your html:form action=/viewJumpCenter in your jumpCenter.jsp file? -jeff On Thursday, March 27, 2003, at 09:35 AM, White, Joshua A (CASD, IT) wrote: I have the following code in my struts config: ... form-bean name=jumpCenterForm type=form.JumpCenterForm / ... ... action path=/viewJumpCenter type=action.ViewJumpCenterAction scope=request name=jumpCenterForm validate=false input=screen.jumpCenter forward name=form path=screen.jumpCenter redirect=false / /action ... ... html:form action=insertUser method=POST ... /html:form ... When the action viewJumpCenter is called, I receive the following error: [ServletException in:/WEB-INF/jsp/jumpCenter.jsp] Cannot retrieve definition for form bean null' What is happening here? I have several other forms setup like this that do not require me to specify the type of form bean in the html:form tag. What else could be causing this error? I put debug statements in the form and action constructors, they are being created fine. Any Ideas? Regards, Joshua This communication, including attachments, is for the exclusive use of addressee and may contain proprietary, confidential or privileged information. If you are not the intended recipient, any use, copying, disclosure, dissemination or distribution is strictly prohibited. If you are not the intended recipient, please notify the sender immediately by return email and delete this communication and destroy all copies. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Exception: Cannot retrieve definition for form bean null using ForwardAction
Hi, I am trying to use a ForwardAction to navigate from one jsp to another. It has been suggested that every JSP Page should be fronted by an Action. I am currently trying to do this, but getting the following exception: javax.servlet.ServletException: Cannot retrieve definition for form bean null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java:530) at org.apache.jsp.leadDetails_jsp._jspService(leadDetails_jsp.java:657) [snip] I don't want to use a form bean because this is just a simple forward request. My form in my jsp looks like this: html:form action=/goback target=body html:submit property=action value= Back/ /html:form My struts-config looks like this: action path=/goback parameter=/jsp/somePage.jsp type=org.apache.struts.actions.ForwardAction scope=request validate=false /action I am using Struts 1.1 RC 1. When I try to load my jsp, I get the exception mentioned above. Can anyone offer any suggestions as to why I would be getting this exception?? Thanks in advance, Damian. www.sensis.com.au A leading Australian advertising, information and directories business. www.yellowpages.com.au www.whitepages.com.au www.citysearch.com.au www.whereis.com.au www.telstra.com.au This email and any attachments are intended only for the use of the recipient and may be confidential and/or legally privileged. Sensis Pty Ltd disclaims liability for any errors, omissions, viruses, loss and/or damage arising from using, opening or transmitting this email. If you are not the intended recipient you must not use, interfere with, disclose, copy or retain this email and you should notify the sender immediately by return email or by contacting Sensis Pty Ltd by telephone on [+61 3 9201 4888]
Re: Exception: Cannot retrieve definition for form bean null using Fo rwardAction
for every form that you have in your app you need a form bean and then u need to add it to your action mapping that is where you are getting the null exception just create a dummy form bean with nothing in it and then add it to that action On Wednesday 26 March 2003 11:22 pm, Alonso, Damian wrote: Hi, I am trying to use a ForwardAction to navigate from one jsp to another. It has been suggested that every JSP Page should be fronted by an Action. I am currently trying to do this, but getting the following exception: javax.servlet.ServletException: Cannot retrieve definition for form bean null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextIm p l.java:530) at org.apache.jsp.leadDetails_jsp._jspService(leadDetails_jsp.java:657) [snip] I don't want to use a form bean because this is just a simple forward request. My form in my jsp looks like this: html:form action=/goback target=body html:submit property=action value= Back/ /html:form My struts-config looks like this: action path=/goback parameter=/jsp/somePage.jsp type=org.apache.struts.actions.ForwardAction scope=request validate=false /action I am using Struts 1.1 RC 1. When I try to load my jsp, I get the exception mentioned above. Can anyone offer any suggestions as to why I would be getting this exception?? Thanks in advance, Damian. www.sensis.com.au A leading Australian advertising, information and directories business. www.yellowpages.com.au www.whitepages.com.au www.citysearch.com.au www.whereis.com.au www.telstra.com.au This email and any attachments are intended only for the use of the recipient and may be confidential and/or legally privileged. Sensis Pty Ltd disclaims liability for any errors, omissions, viruses, loss and/or damage arising from using, opening or transmitting this email. If you are not the intended recipient you must not use, interfere with, disclose, copy or retain this email and you should notify the sender immediately by return email or by contacting Sensis Pty Ltd by telephone on [+61 3 9201 4888] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Form bean null
Hi, I'm new to Struts. I am trying to use an exsiting jsp file in a new project and received the following error when trying to display it: [ServletException in:/jsps/addAssociate.jsp] Cannot retrieve definition for form bean null' Anyone know where I should look to fix this? General info on what makes this occur? Thanks, John - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Form bean null
http://marc.theaimsgroup.com/?l=struts-userw=2r=1s=form+bean+nullq=b -= J -Original Message- From: Curley, John [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 20, 2003 8:32 AM To: '[EMAIL PROTECTED]' Subject: Form bean null Hi, I'm new to Struts. I am trying to use an exsiting jsp file in a new project and received the following error when trying to display it: [ServletException in:/jsps/addAssociate.jsp] Cannot retrieve definition for form bean null' Anyone know where I should look to fix this? General info on what makes this occur? Thanks, John - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Form bean null
http://marc.theaimsgroup.com/?l=struts-userw=2r=1s=Cannot+retrieve+defini tion+for+form+beanq=b -- Voytek Jarnot Quidquid latine dictum sit, altum viditur. -Original Message- From: Curley, John [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 20, 2003 8:32 AM To: '[EMAIL PROTECTED]' Subject: Form bean null Hi, I'm new to Struts. I am trying to use an exsiting jsp file in a new project and received the following error when trying to display it: [ServletException in:/jsps/addAssociate.jsp] Cannot retrieve definition for form bean null' Anyone know where I should look to fix this? General info on what makes this occur? Thanks, John - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Form bean null
Usually an indication that your setup is incorrect -- no name attribute for a mapping that uses html:form etc. Please take a look at the archives for previous references to the problem for hints. You can search using various tools. Take your pick of : http://marc.theaimsgroup.com/?l=struts-user http://nagoya.apache.org/eyebrowse/SearchList?[EMAIL PROTECTED] http://www.mail-archive.com/struts-user%40jakarta.apache.org/ Sri -Original Message- From: Curley, John [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 20, 2003 9:32 AM To: '[EMAIL PROTECTED]' Subject: Form bean null Hi, I'm new to Struts. I am trying to use an exsiting jsp file in a new project and received the following error when trying to display it: [ServletException in:/jsps/addAssociate.jsp] Cannot retrieve definition for form bean null' Anyone know where I should look to fix this? General info on what makes this occur? Thanks, John - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Form bean null
You might also try Google ;-) (You'll be amazed! Try it!) Sri Sankaran wrote: Usually an indication that your setup is incorrect -- no name attribute for a mapping that uses html:form etc. Please take a look at the archives for previous references to the problem for hints. You can search using various tools. Take your pick of : http://marc.theaimsgroup.com/?l=struts-user http://nagoya.apache.org/eyebrowse/SearchList?[EMAIL PROTECTED] http://www.mail-archive.com/struts-user%40jakarta.apache.org/ Sri -Original Message- From: Curley, John [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 20, 2003 9:32 AM To: '[EMAIL PROTECTED]' Subject: Form bean null Hi, I'm new to Struts. I am trying to use an exsiting jsp file in a new project and received the following error when trying to display it: [ServletException in:/jsps/addAssociate.jsp] Cannot retrieve definition for form bean null' Anyone know where I should look to fix this? General info on what makes this occur? Thanks, John -- Eddie Bush - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Error 500: Cannot retrieve definition for form bean null
Set u r form bean in either request r in session.The session r request key should be u r name of u r formbean Ex: request.setAttribute(UpdateOrderForm,objectrefernce); Thanks, Nadeem, Wipro Technologies,Chennai Tel - 91-44-4500200 X : 2111 Mobile : 98401 47663 -Original Message- From: MarwanSalam [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Friday, February 14, 2003 6:42 AM To: [EMAIL PROTECTED] Subject: Error 500: Cannot retrieve definition for form bean null Hi, I am getting Error 500: Cannot retrieve definition for form bean null when I use the form tag html:form action=/updateOrder.do. However, if I use form action=updateOrder.do method=post, I don't get that error. Is there something wrong I am doing? Here is the action-mapping from struts-config: actionpath=/updateOrder type=mypackage.UpdateOrdersAction name=updateOrderForm scope=session validate=false input=/updateorder.jsp forward name=update path=/showorderdetails.jsp/ forward name=edit path=/updateorder.jsp/ /action Here is my form-bean definition from struts-config: form-bean name=updateOrderForm type=mypackage.UpdateOrderForm/ Thanks, Marwan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] **Disclaimer** Information contained in this E-MAIL being proprietary to Wipro Limited is 'privileged' and 'confidential' and intended for use only by the individual or entity to which it is addressed. You are notified that any use, copying or dissemination of the information contained in the E-MAIL in any manner whatsoever is strictly prohibited. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Error 500: Cannot retrieve definition for form bean null
Ignore if you already fixed this, but the tag usage should be: html:form action=/updateOrder not: html:form action=/updateOrder.do The reason for this is so Struts can append the extension that you defined in the servlet mapping (e.g. .do)--this way you can change the servlet mapping later without changing any of your html:form tags in your jsps. :) --joe -Original Message- From: MarwanSalam [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 13, 2003 5:12 PM To: [EMAIL PROTECTED] Subject: Error 500: Cannot retrieve definition for form bean null Hi, I am getting Error 500: Cannot retrieve definition for form bean null when I use the form tag html:form action=/updateOrder.do. However, if I use form action=updateOrder.do method=post, I don't get that error. Is there something wrong I am doing? Here is the action-mapping from struts-config: actionpath=/updateOrder type=mypackage.UpdateOrdersAction name=updateOrderForm scope=session validate=false input=/updateorder.jsp forward name=update path=/showorderdetails.jsp/ forward name=edit path=/updateorder.jsp/ /action Here is my form-bean definition from struts-config: form-bean name=updateOrderForm type=mypackage.UpdateOrderForm/ Thanks, Marwan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Cannot retrieve definition for form bean null
Yes, this is the name of the class. I checked this 100s of times, even copying and pasting the package and class name from the .java file. I'm sure this is correct. I have Struts logging turned up to #6 but that isn't putting out any messages. There is very little in the JSP so I don't think that logging directly from the JSP would help. There is no body to the JSP. This is irrelevant. Right now you have no idea if any part of your JSP actually executes, or if the bug occurs before it's service method is even called. Putting logging statements there will enable you to determine that. You can also put a scriplet in to grab your form directly from the request to see if it's actually there, etc. If it's not there, that means there's either something wrong with your struts-config (like maybe the form-bean element is missing, so struts doesn't know what form bean class to instantiate), struts couldn't find the form class (though that should throw a different exception), or you are hitting the JSP directly without going through a struts-mapped url. hope this helps, Joe Joe Barefoot [EMAIL PROTECTED] wrote:Is your form bean class actually named: com.client.form.simpleForm ? or is supposed to have a capital 'S': com.client.form.SimpleForm ? Have you tried putting any logging statements into the simplePage.jsp (just sys-outs would work)? You should put a few in so that you can see exactly where/when the exception is occuring...it may even be thrown before the JSP is actually executed. peace, Joe -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 1:38 PM To: Struts Users Mailing List Subject: RE: Cannot retrieve definition for form bean null I am not referencing my own bean. The only thing my JSP tries to do is grab a value from a resource bundle and set the title of the page to that value. This is my entire JSP: This is the config file: type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ type=com.client.action.LogonAction name=logonForm scope=request validate=true input=Logon.jsp type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ James Childers wrote: Nine times out of ten when I get that message it is one of two things: - I haven't referenced the bean properly in the tag. This is especially true of anything which references a collection, because that syntax is just off. - I haven't put the bean in the proper scope. Less frequent, but it happens. BTW: Your struts-config and JSP source is coming across as blanks on my mailreader. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:19 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml
Error 500: Cannot retrieve definition for form bean null
Hi, I am getting Error 500: Cannot retrieve definition for form bean null when I use the form tag html:form action=/updateOrder.do. However, if I use form action=updateOrder.do method=post, I don't get that error. Is there something wrong I am doing? Here is the action-mapping from struts-config: actionpath=/updateOrder type=mypackage.UpdateOrdersAction name=updateOrderForm scope=session validate=false input=/updateorder.jsp forward name=update path=/showorderdetails.jsp/ forward name=edit path=/updateorder.jsp/ /action Here is my form-bean definition from struts-config: form-bean name=updateOrderForm type=mypackage.UpdateOrderForm/ Thanks, Marwan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Error 500: Cannot retrieve definition for form bean null
Are you sure fields of bean UpdateOrderForm.java match (get/set) fields in your html form. jim MarwanSalam wrote: Hi, I am getting Error 500: Cannot retrieve definition for form bean null when I use the form tag html:form action=/updateOrder.do. However, if I use form action=updateOrder.do method=post, I don't get that error. Is there something wrong I am doing? Here is the action-mapping from struts-config: actionpath=/updateOrder type=mypackage.UpdateOrdersAction name=updateOrderForm scope=session validate=false input=/updateorder.jsp forward name=update path=/showorderdetails.jsp/ forward name=edit path=/updateorder.jsp/ /action Here is my form-bean definition from struts-config: form-bean name=updateOrderForm type=mypackage.UpdateOrderForm/ Thanks, Marwan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cannot retrieve definition for form bean null
Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: struts-config form-beans form-bean name=simpleForm type=com.company.simpleForm/ form-bean name=logonForm type=com.company.LogonForm/ /form-beans global-forwards type=org.apache.struts.action.ActionForward forward name=logoff path=/Logoff.do/ forward name=logon path=/Logon.do/ forward name=welcome path=/Welcome.do/ /global-forwards action-mappings action path=/Welcome type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ action path=/Logon type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ action path=/LogonSubmit type=com.company.LogonAction name=logonForm scope=request validate=true input=Logon.jsp forward name=success path=simplePage.jsp/ /action action path=/Logoff type=LogoffAction forward name=success path=Welcome.jsp/ /action action path=/simplePage type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ /action-mappings /struts-config Here is my JSP: !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN %@ page language=java % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % html:html head link rel=stylesheet href=include/format.css type=text/css/ /head title html:base/ bean:message key=simplePage.title/ /title body /body /html:html - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day
RE: Cannot retrieve definition for form bean null
I'm not sure if this is your problem, but do you have the tld directive in your jsp? %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 1:43 PM To: Struts Mailing List Subject: Cannot retrieve definition for form bean null Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: struts-config form-beans form-bean name=simpleForm type=com.company.simpleForm/ form-bean name=logonForm type=com.company.LogonForm/ /form-beans global-forwards type=org.apache.struts.action.ActionForward forward name=logoff path=/Logoff.do/ forward name=logon path=/Logon.do/ forward name=welcome path=/Welcome.do/ /global-forwards action-mappings action path=/Welcome type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ action path=/Logon type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ action path=/LogonSubmit type=com.company.LogonAction name=logonForm scope=request validate=true input=Logon.jsp forward name=success path=simplePage.jsp/ /action action path=/Logoff type=LogoffAction forward name=success path=Welcome.jsp/ /action action path=/simplePage type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ /action-mappings /struts-config Here is my JSP: !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN %@ page language=java % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % html:html head link rel=stylesheet href=include/format.css type=text/css/ /head title html:base/ bean:message key=simplePage.title/ /title body /body /html:html - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Cannot retrieve definition for form bean null
Yes, I do. The entire JSP was included in my message and appears at the bottom of this one as well. As you can see, it is quite simple. All I want is to retrieve a value from the resource bundle and set it as the page's title. Kandi Potter [EMAIL PROTECTED] wrote:I'm not sure if this is your problem, but do you have the tld directive in your jsp? -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 1:43 PM To: Struts Mailing List Subject: Cannot retrieve definition for form bean null Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day
Re: Cannot retrieve definition for form bean null
I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay [EMAIL PROTECTED] wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day
RE: Cannot retrieve definition for form bean null
Nine times out of ten when I get that message it is one of two things: - I haven't referenced the bean properly in the tag. This is especially true of anything which references a collection, because that syntax is just off. - I haven't put the bean in the proper scope. Less frequent, but it happens. BTW: Your struts-config and JSP source is coming across as blanks on my mailreader. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:19 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay [EMAIL PROTECTED] wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Cannot retrieve definition for form bean null
I am not referencing my own bean. The only thing my JSP tries to do is grab a value from a resource bundle and set the title of the page to that value. This is my entire JSP: html:html head link rel=stylesheet href=include/style.css type=text/css/ /head title bean:message key=simplePage.title/ /title body /body /html:html This is the config file: struts-config form-beans form-bean name=simpleForm type=com.client.form.simpleForm/ form-bean name=logonForm type=com.client.form.LogonForm/ /form-beans global-forwards type=org.apache.struts.action.ActionForward forward name=logoff path=/Logoff.do/ forward name=logon path=/Logon.do/ forward name=welcome path=/Welcome.do/ /global-forwards action-mappings action path=/Welcome type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ action path=/Logon type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ action path=/LogonSubmit type=com.client.action.LogonAction name=logonForm scope=request validate=true input=Logon.jsp forward name=success path=simplePage.jsp/ /action action path=/Logoff type=LogoffAction forward name=success path=Welcome.jsp/ /action action path=/simplePage name=simpleForm type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ /action-mappings /struts-config James Childers [EMAIL PROTECTED] wrote: Nine times out of ten when I get that message it is one of two things: - I haven't referenced the bean properly in the tag. This is especially true of anything which references a collection, because that syntax is just off. - I haven't put the bean in the proper scope. Less frequent, but it happens. BTW: Your struts-config and JSP source is coming across as blanks on my mailreader. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:19 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day
RE: Cannot retrieve definition for form bean null
This sounds like it's an issue with your resources file. Make sure it's being referenced properly in web.xml and is in a directory under WEB-INF\classes which corresponds to its package. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:38 PM To: Struts Users Mailing List Subject: RE: Cannot retrieve definition for form bean null I am not referencing my own bean. The only thing my JSP tries to do is grab a value from a resource bundle and set the title of the page to that value. This is my entire JSP: html:html head link rel=stylesheet href=include/style.css type=text/css/ /head title bean:message key=simplePage.title/ /title body /body /html:html This is the config file: struts-config form-beans form-bean name=simpleForm type=com.client.form.simpleForm/ form-bean name=logonForm type=com.client.form.LogonForm/ /form-beans global-forwards type=org.apache.struts.action.ActionForward forward name=logoff path=/Logoff.do/ forward name=logon path=/Logon.do/ forward name=welcome path=/Welcome.do/ /global-forwards action-mappings action path=/Welcome type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ action path=/Logon type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ action path=/LogonSubmit type=com.client.action.LogonAction name=logonForm scope=request validate=true input=Logon.jsp forward name=success path=simplePage.jsp/ /action action path=/Logoff type=LogoffAction forward name=success path=Welcome.jsp/ /action action path=/simplePage name=simpleForm type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ /action-mappings /struts-config James Childers [EMAIL PROTECTED] wrote: Nine times out of ten when I get that message it is one of two things: - I haven't referenced the bean properly in the tag. This is especially true of anything which references a collection, because that syntax is just off. - I haven't put the bean in the proper scope. Less frequent, but it happens. BTW: Your struts-config and JSP source is coming across as blanks on my mailreader. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:19 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED
RE: Cannot retrieve definition for form bean null
Is your form bean class actually named: com.client.form.simpleForm ? or is supposed to have a capital 'S': com.client.form.SimpleForm ? Have you tried putting any logging statements into the simplePage.jsp (just sys-outs would work)? You should put a few in so that you can see exactly where/when the exception is occuring...it may even be thrown before the JSP is actually executed. peace, Joe -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 1:38 PM To: Struts Users Mailing List Subject: RE: Cannot retrieve definition for form bean null I am not referencing my own bean. The only thing my JSP tries to do is grab a value from a resource bundle and set the title of the page to that value. This is my entire JSP: html:html head link rel=stylesheet href=include/style.css type=text/css/ /head title bean:message key=simplePage.title/ /title body /body /html:html This is the config file: struts-config form-beans form-bean name=simpleForm type=com.client.form.simpleForm/ form-bean name=logonForm type=com.client.form.LogonForm/ /form-beans global-forwards type=org.apache.struts.action.ActionForward forward name=logoff path=/Logoff.do/ forward name=logon path=/Logon.do/ forward name=welcome path=/Welcome.do/ /global-forwards action-mappings action path=/Welcome type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ action path=/Logon type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ action path=/LogonSubmit type=com.client.action.LogonAction name=logonForm scope=request validate=true input=Logon.jsp forward name=success path=simplePage.jsp/ /action action path=/Logoff type=LogoffAction forward name=success path=Welcome.jsp/ /action action path=/simplePage name=simpleForm type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ /action-mappings /struts-config James Childers [EMAIL PROTECTED] wrote: Nine times out of ten when I get that message it is one of two things: - I haven't referenced the bean properly in the tag. This is especially true of anything which references a collection, because that syntax is just off. - I haven't put the bean in the proper scope. Less frequent, but it happens. BTW: Your struts-config and JSP source is coming across as blanks on my mailreader. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:19 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day
RE: Cannot retrieve definition for form bean null
Yes, this is the name of the class. I checked this 100s of times, even copying and pasting the package and class name from the .java file. I'm sure this is correct. I have Struts logging turned up to #6 but that isn't putting out any messages. There is very little in the JSP so I don't think that logging directly from the JSP would help. There is no body to the JSP. Joe Barefoot [EMAIL PROTECTED] wrote:Is your form bean class actually named: com.client.form.simpleForm ? or is supposed to have a capital 'S': com.client.form.SimpleForm ? Have you tried putting any logging statements into the simplePage.jsp (just sys-outs would work)? You should put a few in so that you can see exactly where/when the exception is occuring...it may even be thrown before the JSP is actually executed. peace, Joe -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 1:38 PM To: Struts Users Mailing List Subject: RE: Cannot retrieve definition for form bean null I am not referencing my own bean. The only thing my JSP tries to do is grab a value from a resource bundle and set the title of the page to that value. This is my entire JSP: This is the config file: type=org.apache.struts.actions.ForwardAction parameter=Welcome.jsp/ type=org.apache.struts.actions.ForwardAction parameter=Logon.jsp/ type=com.client.action.LogonAction name=logonForm scope=request validate=true input=Logon.jsp type=org.apache.struts.actions.ForwardAction parameter=simplePage.jsp/ James Childers wrote: Nine times out of ten when I get that message it is one of two things: - I haven't referenced the bean properly in the tag. This is especially true of anything which references a collection, because that syntax is just off. - I haven't put the bean in the proper scope. Less frequent, but it happens. BTW: Your struts-config and JSP source is coming across as blanks on my mailreader. -= J -Original Message- From: Art Vandalay [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 12, 2003 3:19 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null I'm sorry to bug everyone again with this, but I cannot figure out what this error message is telling me. If anyone has any insight, I'd appreciate it. After looking through the Struts 1.1 source files, I've determined that this is the code that throws the exception. It is located in FormTag.lookup: // Look up the form bean definition FormBeanConfig formBeanConfig = moduleConfig.findFormBeanConfig(mapping.getName()); if (formBeanConfig == null) { JspException e = new JspException(messages.getMessage(formTag.formBean, mapping.getName())); pageContext.setAttribute(Globals.EXCEPTION_KEY, e, PageContext.REQUEST_SCOPE); throw e; } My original message is below with the struts-config.xml and JSP page itself. Thanks for any help you can provide. Art Vandalay wrote: Hello everyone, I am trying to write a very simple Struts application that simply displays a JSP using bean:message to retrieve values for my field labels and buttons from a ResourceBundle. Pretty straight forward, but I am getting the following error: [exec] javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null The message seems to imply that Struts is trying to access a bean whose name is null but I don't know what bean that would be as I have no beans referenced on my JSP. I am only trying to invoke the logic contained within the struts-bean.tld. The logic flow is the user signs-into the application and is then forwarded to simplePage.jsp. I used a ForwardAction to navigate from the logon page (after a successful login). But I never reach simplePage.jsp due to the above mentioned error. Any help would be appreciated. Here is what I have in my struts_config.xml: Here is my JSP: - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional
Newbie: Cannot retrieve definition for form bean null
Can someone help me out here.. I have no actions/forms, only an applicationResources.properties and jsp that has an action declared in struts-config.xml as : action path=/index forward=/tour.htm /action this is really simple i know.. but i cant find an explanation for this error anywhere. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie: Cannot retrieve definition for form bean null
Hi James What is the error you are getting? Scott On Tue, 2003-02-11 at 21:11, James Prance wrote: Can someone help me out here.. I have no actions/forms, only an applicationResources.properties and jsp that has an action declared in struts-config.xml as : action path=/index forward=/tour.htm /action this is really simple i know.. but i cant find an explanation for this error anywhere. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie: Cannot retrieve definition for form bean null
Hi scott.. got it sorted now.. the actual error was in the subject: Cannot retrieve definition for form bean null Thanks anyway.. James Scott Barr [EMAIL PROTECTED] wrote in message 1044966196.1116.9.camel@cypher">news:1044966196.1116.9.camel@cypher... Hi James What is the error you are getting? Scott On Tue, 2003-02-11 at 21:11, James Prance wrote: Can someone help me out here.. I have no actions/forms, only an applicationResources.properties and jsp that has an action declared in struts-config.xml as : action path=/index forward=/tour.htm /action this is really simple i know.. but i cant find an explanation for this error anywhere. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie: Cannot retrieve definition for form bean null
Theres my fantastic reading skills coming to the forefront again! Scott On Wed, 2003-02-12 at 00:33, James Prance wrote: Hi scott.. got it sorted now.. the actual error was in the subject: Cannot retrieve definition for form bean null Thanks anyway.. James Scott Barr [EMAIL PROTECTED] wrote in message 1044966196.1116.9.camel@cypher">news:1044966196.1116.9.camel@cypher... Hi James What is the error you are getting? Scott On Tue, 2003-02-11 at 21:11, James Prance wrote: Can someone help me out here.. I have no actions/forms, only an applicationResources.properties and jsp that has an action declared in struts-config.xml as : action path=/index forward=/tour.htm /action this is really simple i know.. but i cant find an explanation for this error anywhere. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cannot retrieve definition for form bean null
Hi, I just started using Struts. I am facing some problems with Struts. I have an actions defined and there is a form bean attached to the action. The web server is calling the action properly upon request, creating the right form bean and passing it to the 'perform' method of the action class. But when I am forwarding the request to the jsp page I am getting the following Exception : [ERROR,EmbeddedCatalinaServiceSX] ApplicationDispatcher[/pportal] Servlet.servic e() for servlet jsp threw exception javax.servlet.ServletException: Cannot retrieve definition for form bean null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCon textImpl.java:457) at org.apache.jsp.sendMail$jsp._jspService(sendMail$jsp.java:384) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspSer vlet.java:202) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3 82) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDisp atcher.java:679) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationD ispatcher.java:431) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDis patcher.java:355) at org.apache.struts.action.ActionServlet.processActionForward(ActionSer vlet.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:159 6) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl icationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF ilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV alve.java:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV alve.java:201) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica torBase.java:518) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve .java:246) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java: 2344) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j ava:164) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatche rValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j ava:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal ve.java:163) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcesso r.java:1011) at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.ja va:1106) Have anyone faced this problem before? Please help me out with the solution. BTW, I am using Struts 1.1. Thanks in advance, Supriyo Saha -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
It sounds like the JSP includes a html:form and the action associated with the form does not have a name property. The html:form tag does not know which action was used to start the current request/response cycle, only where it is suppose to submit to start the next cycle. -- Ted Husted, Husted dot Com, Fairport NY US -- Developing Java Web Applications with Struts -- Tel: +1 585 737-3463 -- Web: http://husted.com/about/services Supriya Saha wrote: Hi, I just started using Struts. I am facing some problems with Struts. I have an actions defined and there is a form bean attached to the action. The web server is calling the action properly upon request, creating the right form bean and passing it to the 'perform' method of the action class. But when I am forwarding the request to the jsp page I am getting the following Exception : [ERROR,EmbeddedCatalinaServiceSX] ApplicationDispatcher[/pportal] Servlet.servic e() for servlet jsp threw exception javax.servlet.ServletException: Cannot retrieve definition for form bean null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCon textImpl.java:457) at org.apache.jsp.sendMail$jsp._jspService(sendMail$jsp.java:384) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspSer vlet.java:202) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3 82) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDisp atcher.java:679) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationD ispatcher.java:431) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDis patcher.java:355) at org.apache.struts.action.ActionServlet.processActionForward(ActionSer vlet.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:159 6) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl icationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF ilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV alve.java:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV alve.java:201) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica torBase.java:518) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve .java:246) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java: 2344) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j ava:164) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatche rValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j ava:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal ve.java:163) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java
RE: Cannot retrieve definition for form bean null
Hi , When you are forwording the request to the jsp page directly. The jsp page implictly populates the page(the page to which you are forwording) with the corresponding form bean. Since the form bean is not instantiated it will give this error. Make sure that form bean is instantiated when the jsp page is also displayed. Bye C.Bhaskaran -Original Message- From: Ted Husted [mailto:[EMAIL PROTECTED]] Sent: Monday, June 10, 2002 10:03 PM To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null It sounds like the JSP includes a html:form and the action associated with the form does not have a name property. The html:form tag does not know which action was used to start the current request/response cycle, only where it is suppose to submit to start the next cycle. -- Ted Husted, Husted dot Com, Fairport NY US -- Developing Java Web Applications with Struts -- Tel: +1 585 737-3463 -- Web: http://husted.com/about/services Supriya Saha wrote: Hi, I just started using Struts. I am facing some problems with Struts. I have an actions defined and there is a form bean attached to the action. The web server is calling the action properly upon request, creating the right form bean and passing it to the 'perform' method of the action class. But when I am forwarding the request to the jsp page I am getting the following Exception : [ERROR,EmbeddedCatalinaServiceSX] ApplicationDispatcher[/pportal] Servlet.servic e() for servlet jsp threw exception javax.servlet.ServletException: Cannot retrieve definition for form bean null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCon textImpl.java:457) at org.apache.jsp.sendMail$jsp._jspService(sendMail$jsp.java:384) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspSer vlet.java:202) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3 82) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDisp atcher.java:679) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationD ispatcher.java:431) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDis patcher.java:355) at org.apache.struts.action.ActionServlet.processActionForward(ActionSer vlet.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:159 6) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl icationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF ilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV alve.java:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV alve.java:201) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica torBase.java:518) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve .java:246) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav a:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java: 2344) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j ava:164) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:566) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatche rValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline .java:564) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j ava:170
Cannot retrieve definition for form bean null
I have a strange feeling I've had this problem before I invoke my action FindCustomerDataAction, wich is supposed to display a form. The action runs ok, and a form bean is made (CardCustomerSearchForm), but when i forward to the correct jsp, I get the the error included below. I include the relevant code from struts-config.xml as well: Can anyone help me?? --- --- javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:795) at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:481) at jsp_servlet._customer.__kort_finn_kunde._jspService(__kort_finn_kunde.java:127) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200) at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:241) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) from struts-config.xml form-beans form-bean name=customerSearchForm type=sb1.business.salesclient.customer.action.CardCustomerSearchForm / /form-beans action path=/customer/search type=sb1.business.salesclient.customer.action.FindCustomerDataAction name=customerSearchForm scope=request input=/customer/kort_finn_kunde.jsp validate=true forward name=displayform path=/customer/kort_finn_kunde.jsp /forward forward name=simplesearchresult path=/customer/show.do /forward forward name=advancedsearchresult path=/customer/searchresult.jsp /forward forward name=failure path=/customer/kort_finn_kunde.jsp /forward forward name=error path=/customer/error.jsp /forward /action ...mogul technology as... mogul technology ida dørum - software engineer drammensveien 134 N - 0277 oslo norway tel +47 - 24 11 43 00 dir +47 - 24 11 44 87 mobil +47 - 930 60 318 mailto:[EMAIL PROTECTED] www.mogul.no ... -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Cannot retrieve definition for form bean null
Don't you miss to transfert your form bean at the end of your action like this : if(form!=null) if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else request.getSession().setAttribute(mapping.getAttribute(), form); arno# -Message d'origine- De: Ida Dorum [SMTP:[EMAIL PROTECTED]] Date: mardi 9 avril 2002 16:54 A:[EMAIL PROTECTED] Objet:Cannot retrieve definition for form bean null I have a strange feeling I've had this problem before I invoke my action FindCustomerDataAction, wich is supposed to display a form. The action runs ok, and a form bean is made (CardCustomerSearchForm), but when i forward to the correct jsp, I get the the error included below. I include the relevant code from struts-config.xml as well: Can anyone help me?? --- --- javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:795) at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:481) at jsp_servlet._customer.__kort_finn_kunde._jspService(__kort_finn_kunde.ja va:127) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatche rImpl.java:241) at org.apache.struts.action.ActionServlet.processActionForward(ActionServle t.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) from struts-config.xml form-beans form-bean name=customerSearchForm type=sb1.business.salesclient.customer.action.CardCustom erSearchForm / /form-beans action path=/customer/search type=sb1.business.salesclient.customer.action.FindCustomerD ataAction name=customerSearchForm scope=request input=/customer/kort_finn_kunde.jsp validate=true forward name=displayform path=/customer/kort_finn_kunde.jsp /forward forward name=simplesearchresult path=/customer/show.do /forward forward name=advancedsearchresult path=/customer/searchresult.jsp /forward forward name=failure path=/customer/kort_finn_kunde.jsp /forward forward name=error path=/customer/error.jsp /forward /action ...mogul technology as... mogul technology ida dorum - software engineer drammensveien 134 N - 0277 oslo norway tel +47 - 24 11 43 00 dir +47 - 24 11 44 87 mobil +47 - 930 60 318 mailto:[EMAIL PROTECTED] www.mogul.no ... -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Cannot retrieve definition for form bean null
The error turned out to be in my mapping, I have never needed to add the form to my request or session in my action to make it available in my jsp? Why do you do that? ida -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: 10. april 2002 11:53 To: 'Struts Users Mailing List' Subject: RE: Cannot retrieve definition for form bean null Don't you miss to transfert your form bean at the end of your action like this : if(form!=null) if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else request.getSession().setAttribute(mapping.getAttribute(), form); arno# -Message d'origine- De: Ida Dorum [SMTP:[EMAIL PROTECTED]] Date: mardi 9 avril 2002 16:54 A:[EMAIL PROTECTED] Objet:Cannot retrieve definition for form bean null I have a strange feeling I've had this problem before I invoke my action FindCustomerDataAction, wich is supposed to display a form. The action runs ok, and a form bean is made (CardCustomerSearchForm), but when i forward to the correct jsp, I get the the error included below. I include the relevant code from struts-config.xml as well: Can anyone help me?? --- --- javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:795) at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:481) at jsp_servlet._customer.__kort_finn_kunde._jspService(__kort_finn_kunde.ja va:127) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatche rImpl.java:241) at org.apache.struts.action.ActionServlet.processActionForward(ActionServle t.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) from struts-config.xml form-beans form-bean name=customerSearchForm type=sb1.business.salesclient.customer.action.CardCustom erSearchForm / /form-beans action path=/customer/search type=sb1.business.salesclient.customer.action.FindCustomerD ataAction name=customerSearchForm scope=request input=/customer/kort_finn_kunde.jsp validate=true forward name=displayform path=/customer/kort_finn_kunde.jsp /forward forward name=simplesearchresult path=/customer/show.do /forward forward name=advancedsearchresult path=/customer/searchresult.jsp /forward forward name=failure path=/customer/kort_finn_kunde.jsp /forward forward name=error path=/customer/error.jsp /forward /action ...mogul technology as... mogul technology ida dorum - software engineer drammensveien 134 N - 0277 oslo norway tel +47 - 24 11 43 00 dir +47 - 24 11 44 87 mobil +47 - 930 60 318 mailto:[EMAIL PROTECTED] www.mogul.no ... -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
Ida Dorum wrote: The error turned out to be in my mapping, I have never needed to add the form to my request or session in my action to make it available in my jsp? Why do you do that? Neither me (?) Could you send an extract of the JSP file? (kort_finn_kunde.jsp) -- C. Bouessay -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: 10. april 2002 11:53 To: 'Struts Users Mailing List' Subject: RE: Cannot retrieve definition for form bean null Don't you miss to transfert your form bean at the end of your action like this : if(form!=null) if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else request.getSession().setAttribute(mapping.getAttribute(), form); arno# -Message d'origine- De: Ida Dorum [SMTP:[EMAIL PROTECTED]] Date: mardi 9 avril 2002 16:54 A:[EMAIL PROTECTED] Objet:Cannot retrieve definition for form bean null I have a strange feeling I've had this problem before I invoke my action FindCustomerDataAction, wich is supposed to display a form. The action runs ok, and a form bean is made (CardCustomerSearchForm), but when i forward to the correct jsp, I get the the error included below. I include the relevant code from struts-config.xml as well: Can anyone help me?? --- --- javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:795) at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:481) at jsp_servlet._customer.__kort_finn_kunde._jspService(__kort_finn_kunde.ja va:127) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatche rImpl.java:241) at org.apache.struts.action.ActionServlet.processActionForward(ActionServle t.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) from struts-config.xml form-beans form-bean name=customerSearchForm type=sb1.business.salesclient.customer.action.CardCustom erSearchForm / /form-beans action path=/customer/search type=sb1.business.salesclient.customer.action.FindCustomerD ataAction name=customerSearchForm scope=request input=/customer/kort_finn_kunde.jsp validate=true forward name=displayform path=/customer/kort_finn_kunde.jsp /forward forward name=simplesearchresult path=/customer/show.do /forward forward name=advancedsearchresult path=/customer/searchresult.jsp /forward forward name=failure path=/customer/kort_finn_kunde.jsp /forward forward name=error path=/customer/error.jsp /forward /action ...mogul technology as... mogul technology ida dorum - software engineer drammensveien 134 N - 0277 oslo norway tel +47 - 24 11 43 00 dir +47 - 24 11 44 87 mobil +47 - 930 60 318 mailto:[EMAIL PROTECTED] www.mogul.no ... -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Cannot retrieve definition for form bean null
It is not really relevant, the error turned out to be that I messed up the action mappings during refactoring. In other words, the code from Arnaud that added the form to the request or session had nothing to do with how I solved my problem. I have never added the form to the session or request in forms I've made earlier either. ida -Original Message- From: Christian Bouessay [mailto:[EMAIL PROTECTED]] Sent: 10. april 2002 14:03 To: Struts Users Mailing List Subject: Re: Cannot retrieve definition for form bean null Ida Dorum wrote: The error turned out to be in my mapping, I have never needed to add the form to my request or session in my action to make it available in my jsp? Why do you do that? Neither me (?) Could you send an extract of the JSP file? (kort_finn_kunde.jsp) -- C. Bouessay -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: 10. april 2002 11:53 To: 'Struts Users Mailing List' Subject: RE: Cannot retrieve definition for form bean null Don't you miss to transfert your form bean at the end of your action like this : if(form!=null) if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else request.getSession().setAttribute(mapping.getAttribute(), form); arno# -Message d'origine- De: Ida Dorum [SMTP:[EMAIL PROTECTED]] Date: mardi 9 avril 2002 16:54 A:[EMAIL PROTECTED] Objet:Cannot retrieve definition for form bean null I have a strange feeling I've had this problem before I invoke my action FindCustomerDataAction, wich is supposed to display a form. The action runs ok, and a form bean is made (CardCustomerSearchForm), but when i forward to the correct jsp, I get the the error included below. I include the relevant code from struts-config.xml as well: Can anyone help me?? --- --- javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:795) at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:481) at jsp_servlet._customer.__kort_finn_kunde._jspService(__kort_finn_kunde.ja va:127) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatche rImpl.java:241) at org.apache.struts.action.ActionServlet.processActionForward(ActionServle t.java:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:265) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) from struts-config.xml form-beans form-bean name=customerSearchForm type=sb1.business.salesclient.customer.action.CardCustom erSearchForm / /form-beans action path=/customer/search type=sb1.business.salesclient.customer.action.FindCustomerD ataAction name=customerSearchForm scope=request input=/customer/kort_finn_kunde.jsp validate=true forward name=displayform path=/customer/kort_finn_kunde.jsp /forward forward name=simplesearchresult path=/customer/show.do /forward forward name=advancedsearchresult path=/customer/searchresult.jsp /forward forward name=failure path=/customer/kort_finn_kunde.jsp /forward forward name=error path=/customer/error.jsp /forward /action ...mogul technology as... mogul technology ida dorum - software engineer drammensveien 134 N - 0277 oslo norway tel +47 - 24 11 43 00 dir +47 - 24 11 44 87 mobil +47 - 930 60 318 mailto:[EMAIL PROTECTED] www.mogul.no
Cannot retrieve definition for form bean null
I have the following config: form-bean name=offerForm type=be.uniway.spofferlt.OfferForm/ /form-beans action-mappings actionpath=/newOffer type=be.uniway.spofferlt.NewOfferAction name=offerForm scope=request validate=false forward name=success path=/jsp/offer.jsp/ /action actionpath=/registrationOffer type=be.uniway.spofferlt.RegistrationOfferAction scope=request forward name=success path=/jsp/offerList.jsp/ /action ... /action-mappings My offer.jsp is the following: html:form action=/registrationOffer.do html:hidden property=action/ ... html:form/ My class be.uniway.spofferlt.NewOfferAction received the form OfferForm and I can set some attributes with setters. The getters are also available. The method perform() of NewOfferAction finishs with the following line: return (mapping.findForward(success)); I receive the error Cannot retrieve definition for form bean null at this moment. Could you help me? I didn't find a answer in the mailinglist. Benoit -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Cannot retrieve definition for form bean null
if u need the form in your offer.jsp(the one you are forwarding from NewOfferAction), you shud have this in your config file actionpath=/registrationOffer type=be.uniway.spofferlt.RegistrationOfferAction name=offerForm scope=request forward name=success path=/jsp/offerList.jsp/ /action This way, you have the Form forwarded to offer.jsp, HTH --- Benoit Segaert [EMAIL PROTECTED] wrote: I have the following config: form-bean name=offerForm type=be.uniway.spofferlt.OfferForm/ /form-beans action-mappings actionpath=/newOffer type=be.uniway.spofferlt.NewOfferAction name=offerForm scope=request validate=false forward name=success path=/jsp/offer.jsp/ /action actionpath=/registrationOffer type=be.uniway.spofferlt.RegistrationOfferAction scope=request forward name=success path=/jsp/offerList.jsp/ /action ... /action-mappings My offer.jsp is the following: html:form action=/registrationOffer.do html:hidden property=action/ ... html:form/ My class be.uniway.spofferlt.NewOfferAction received the form OfferForm and I can set some attributes with setters. The getters are also available. The method perform() of NewOfferAction finishs with the following line: return (mapping.findForward(success)); I receive the error Cannot retrieve definition for form bean null at this moment. Could you help me? I didn't find a answer in the mailinglist. Benoit -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Form bean - null
you declare an action 'editStream' which you tell to use a form called 'MyForm' but afterwards you call an action called 'details'. Is the 'name=MyForm ' line in the declaration of 'details'action ?? On Thu, 14 Feb 2002 11:36:14 +0200 Konstantina Stamopoulou [EMAIL PROTECTED] wrote: Hello, I need to use a form bean in struts and this is the first time I'm doing that .So as newbie I feel I'm missing something basic. Can U help me? This is my case. I have my struts-config : form-beans form-bean name=MyForm type=provider.test.MyForm/ /form-beans actionpath=/editStream type=provider.test.MyFormAction name=MyForm scope=request validate=false forward name=success path=/streaming.jsp/ /action I have MyForm Bean with set and get methods and I have MyForm Action which just initializes my form: . if (form == null) { System.out.println(Form is null); form = new MyForm(); if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else session.setAttribute(mapping.getAttribute(), form); } MyForm strmform = (MyForm) form; and finally my .jsp is the following: html:form action=/details tr font size=5 color=#A0 Destination IP Address : /font html:text property=ip1 size=3 / font color=#A0 . /font html:text property=ip2 size=3 / font color=#A0 . /font html:text property=ip3 size=3 / font color=#A0 . /font html:text property=ip4 size=3 / font color=#A0 . /font /tr tr html:text property=port size=3 / font color=#A0 /tr tr html:text property=lan size=3 / font color=#A0 /tr tr html:text property=autostart size=3 / font color=#A0 /tr /html:form When I callthis page I get a : javax.servlet.ServletException: Cannot retrieve definition for form bean null error, and I cannot fingure out what I 'm doing wrong. I would appriciated if U could provide me with any info regarding this problem. Thank U in advance, Konstantina -- Get your firstname@lastname email at http://Nameplanet.com/?su -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Form bean - null
Hi Konstantina, How do you call your page? If you first call is not like .do, then the action will not be invoked, therefore the form bean is not initialized. Marcel -Original Message- From: Konstantina Stamopoulou [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 14, 2002 10:36 AM To: Struts Users Mailing List Subject: Form bean - null Hello, I need to use a form bean in struts and this is the first time I'm doing that .So as newbie I feel I'm missing something basic. Can U help me? This is my case. I have my struts-config : form-beans form-bean name=MyForm type=provider.test.MyForm/ /form-beans actionpath=/editStream type=provider.test.MyFormAction name=MyForm scope=request validate=false forward name=success path=/streaming.jsp/ /action I have MyForm Bean with set and get methods and I have MyForm Action which just initializes my form: . if (form == null) { System.out.println(Form is null); form = new MyForm(); if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else session.setAttribute(mapping.getAttribute(), form); } MyForm strmform = (MyForm) form; and finally my .jsp is the following: html:form action=/details tr font size=5 color=#A0 Destination IP Address : /font html:text property=ip1 size=3 / font color=#A0 . /font html:text property=ip2 size=3 / font color=#A0 . /font html:text property=ip3 size=3 / font color=#A0 . /font html:text property=ip4 size=3 / font color=#A0 . /font /tr tr html:text property=port size=3 / font color=#A0 /tr tr html:text property=lan size=3 / font color=#A0 /tr tr html:text property=autostart size=3 / font color=#A0 /tr /html:form When I callthis page I get a : javax.servlet.ServletException: Cannot retrieve definition for form bean null error, and I cannot fingure out what I 'm doing wrong. I would appriciated if U could provide me with any info regarding this problem. Thank U in advance, Konstantina -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Form bean - null
Well, Actually my error was that I was associating MyForm with the wrong action. Thank U for pointing that out. Konstantina On Thu, 14 Feb 2002 11:36:14 +0200 Konstantina Stamopoulou [EMAIL PROTECTED] wrote: Hello, I need to use a form bean in struts and this is the first time I'm doing that .So as newbie I feel I'm missing something basic. Can U help me? This is my case. I have my struts-config : form-beans form-bean name=MyForm type=provider.test.MyForm/ /form-beans actionpath=/editStream type=provider.test.MyFormAction name=MyForm scope=request validate=false forward name=success path=/streaming.jsp/ /action I have MyForm Bean with set and get methods and I have MyForm Action which just initializes my form: . if (form == null) { System.out.println(Form is null); form = new MyForm(); if (request.equals(mapping.getScope())) request.setAttribute(mapping.getAttribute(), form); else session.setAttribute(mapping.getAttribute(), form); } MyForm strmform = (MyForm) form; and finally my .jsp is the following: html:form action=/details tr font size=5 color=#A0 Destination IP Address : /font html:text property=ip1 size=3 / font color=#A0 . /font html:text property=ip2 size=3 / font color=#A0 . /font html:text property=ip3 size=3 / font color=#A0 . /font html:text property=ip4 size=3 / font color=#A0 . /font /tr tr html:text property=port size=3 / font color=#A0 /tr tr html:text property=lan size=3 / font color=#A0 /tr tr html:text property=autostart size=3 / font color=#A0 /tr /html:form When I callthis page I get a : javax.servlet.ServletException: Cannot retrieve definition for form bean null error, and I cannot fingure out what I 'm doing wrong. I would appriciated if U could provide me with any info regarding this problem. Thank U in advance, Konstantina -- Get your firstname@lastname email at http://Nameplanet.com/?su -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Cannot retrieve definition for form bean null?
In my action mapping is a form definition optional or not? In this case I have no need to define an ActionForm so I left it off the action mapping in the struts config file: forward name=adminbillertestadd path=/adminbillertestadd.do/ actionpath=/adminbillertestadd type=com.bellhowell.eroute.web.admin.AdminBillerAddAction scope=request input=/adminbillertestadd.jsp forward name=success path=/adminbilleradd.jsp/ forward name=error path=/error.jsp/ /action In my JSP it looks like: %@ page language=java % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titleADMIN BILLER TEST ADD PAGE/title /head body bgcolor=white html:form action=adminbillertestadd html:submit property=submit value=Submit/ /html:form /body /html:html But when I try it in the browser I get: 500 Internal Server Error javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:795) at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:481) at /adminbillertestadd.jsp._jspService(/adminbillertestadd.jsp.java:42) (JSP page line 10) And yes, in my web.xml I do have the tag libs declared. What is wrong? TIA! Erich Kilmer Bell+Howell RTP, NC
Re: Cannot retrieve definition for form bean null?
Defining a form in your action is definately optional, not sure why you would get that error message - though I have had errors reporting null beans that were acctually masking a different problem. Sorry I couldn't be more help, good luck. Nicola Rankin ** This message (and any files transmitted with it) are confidential and may be legally privileged. If you are not the intended recipient please notify the sender immediately and delete this message from your system. This message does not necessarily reflect the views of the Reserve Bank of New Zealand. If the recipient has any concerns about the content of this message they should seek alternative confirmation from the Reserve Bank of New Zealand. **
Re: Cannot retrieve definition for form bean null
On Fri, 6 Apr 2001, Abraham Kang wrote: Does anyone know what this exception means? javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null I have a simple JSP page that only has two Struts tags: html:form ... /html:form We'd need to see the details of your html:form tag and struts-config.xml file to be sure, but I would bet there is a mismatch somewhere -- perhaps an incorrect class name on the form-bean element. Confused, Abraham Craig
Cannot retrieve definition for form bean null
Does anyone know what this exception means? javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null I have a simple JSP page that only has two Struts tags: html:form ... /html:form Confused, Abraham