Hi, Pls. use this tips :
http://www.jguru.com/forums/view.jsp?EID=1256030 thx bb On Tue, May 4, 2010 at 12:33 PM, Kamala Kannan JS <kannanmc...@gmail.com>wrote: > Hi friends, > Am doing a code for search for a website. After uploading to server > it shows error as i mentioned below. > > > javax.servlet.jsp.JspException: Exception creating bean of class > Form.DbForm: > {1} > at org.apache.struts.taglib.html.FormTag.initFormBean(FormTag.java:465) > at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:432) > at _testsearch__jsp._jspService(/testsearch.jsp:20) > at com.caucho.jsp.JavaPage.service(JavaPage.java:75) > at com.caucho.jsp.Page.subservice(Page.java:506) > at > com.caucho.server.http.FilterChainPage.doFilter(FilterChainPage.java:182) > at com.caucho.server.http.Invocation.service(Invocation.java:315) > at > com.caucho.server.http.CacheInvocation.service(CacheInvocation.java:135) > at > com.caucho.server.http.RunnerRequest.handleRequest(RunnerRequest.java:346) > at > com.caucho.server.http.RunnerRequest.handleConnection(RunnerRequest.java:274) > at com.caucho.server.TcpConnection.run(TcpConnection.java:139) > at java.lang.Thread.run(Thread.java:595) > > * > Struts-config.xml file* > > <?xml version="1.0" encoding="ISO-8859-1" ?> > <!DOCTYPE struts-config PUBLIC > "-//Apache Software Foundation//DTD Struts Configuration 1.1//EN" > "http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd"> > <struts-config> > <form-beans> > <form-bean name="ActionForm" type="Form.DbForm"/> > > </form-beans> > <action-mappings> > <action path="/Search" name="ActionForm" type="Action.DbAction" > > <forward name="success" path="/testsearch.jsp"></forward> > </action> > <action path="/Posting" name="ActionForm" > type="Action.PostingAction" > > <forward name="success" path ="/testpost_success.jsp"></forward> > </action> > </action-mappings> > </struts-config> > > * > Form.DbForm* > > package Form; > > import java.util.ArrayList; > > import org.apache.struts.action.ActionForm; > > public class DbForm extends ActionForm{ > private String Posttitle =null; > private String Postcontent=null; > private String user = null; > private String category=null; > private String select=null; > private String search =null; > private String last=null; > private String title =null; > private String content = null; > private String Location=null; > private ArrayList categoryList= new ArrayList() ; > private ArrayList PostList= new ArrayList() ; > public String getPosttitle() { > return Posttitle; > } > public void setPosttitle(String posttitle) { > Posttitle = posttitle; > } > public String getPostcontent() { > return Postcontent; > } > public void setPostcontent(String postcontent) { > Postcontent = postcontent; > } > public String getLast() { > return last; > } > > > > > public String getUser() { > return user; > } > public void setUser(String user) { > this.user = user; > } > > > public String getCategory() { > return category; > } > > public void setCategory(String category) { > this.category = category; > } > > > > public String getSelect() { > return select; > } > > public void setSelect(String select) { > this.select = select; > } > public void setLast(String last) { > this.last = last; > } > > public String getSearch() { > return search; > } > > public void setSearch(String search) { > this.search = search; > } > > > > > > > public ArrayList getCategoryList() { > return categoryList; > } > public void setCategoryList(ArrayList categoryList) { > this.categoryList = categoryList; > } > > public String getTitle() { > return title; > } > > public void setTitle(String title) { > this.title = title; > } > > public String getSubcategory() { > return subcategory; > } > > public void setSubcategory(String subcategory) { > this.subcategory = subcategory; > } > > private String subcategory = null; > > private String myDate=null; > > public String getMyDate() { > return myDate; > } > > public void setMyDate(String myDate) { > this.myDate = myDate; > } > public String getContent() { > return content; > } > public void setContent(String content) { > this.content = content; > } > public String getLocation() { > return Location; > } > public void setLocation(String location) { > Location = location; > } > > public ArrayList getPostList() { > return PostList; > } > public void setPostList(ArrayList postList) { > PostList = postList; > } > } > > * > DbAction* > > package Action; > > import java.util.ArrayList; > > import javax.servlet.http.HttpServletRequest; > import javax.servlet.http.HttpServletResponse; > > import org.apache.struts.action.Action; > import org.apache.struts.action.ActionForm; > import org.apache.struts.action.ActionForward; > import org.apache.struts.action.ActionMapping; > > import dao.WeeberDAO; > > import Form.DbForm; > > public class DbAction extends Action { > > public ActionForward execute (ActionMapping map, ActionForm form, > HttpServletRequest req, HttpServletResponse Res) > { > DbForm dbForm=(DbForm)form; > WeeberDAO weeberDAO=new WeeberDAO(); > ArrayList list=weeberDAO.selectUser(dbForm); > > dbForm.setCategoryList(list); > > //////ArrayList myList=weeberDAO.search(dbForm); > //dbForm.setSearchList(myList); > return map.findForward("success"); > } > } > > * > PostingAction* > > package Action; > > import java.util.ArrayList; > > import javax.servlet.http.HttpServletRequest; > import javax.servlet.http.HttpServletResponse; > > import org.apache.struts.action.Action; > import org.apache.struts.action.ActionForm; > import org.apache.struts.action.ActionForward; > import org.apache.struts.action.ActionMapping; > > import Form.DbForm; > import dao.WeeberDAO; > > public class PostingAction extends Action{ > > public ActionForward execute(ActionMapping map, ActionForm > form,HttpServletRequest req, HttpServletResponse res) > { > DbForm dbForm=(DbForm)form; > WeeberDAO weeberDAO=new WeeberDAO(); > weeberDAO.post(dbForm); > > > return map.findForward("success"); > } > > } > > > Help me pls to rectify this issue > > > > Thanks and regards, > Kamalakannan JS > > > -- > You received this message because you are subscribed to the Google > Groups "Java EE (J2EE) Programming with Passion!" group. > To post to this group, send email to > java-ee-j2ee-programming-with-passion@googlegroups.com > To unsubscribe from this group, send email to > java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com<java-ee-j2ee-programming-with-passion%2bunsubscr...@googlegroups.com> > For more options, visit this group at > > http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en -- You received this message because you are subscribed to the Google Groups "Java EE (J2EE) Programming with Passion!" group. To post to this group, send email to java-ee-j2ee-programming-with-passion@googlegroups.com To unsubscribe from this group, send email to java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en