jQuery in Action, 2nd edition*
The moose likes Struts and the fly likes Intilization of form data Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Intilization of form data" Watch "Intilization of form data" New topic
Author

Intilization of form data

Mohammad Akon
Greenhorn

Joined: Jul 17, 2007
Posts: 19
Hi all,

Is it possible to initialize a form's fields with the information retrieved from a datasource?? If so.... how?

- mohammad
Mohammad Akon
Greenhorn

Joined: Jul 17, 2007
Posts: 19
Actually I am trying to create a edit profile page.....

my configurations are as follows:

struts-config.xml


EditProfileForm.java


EditProfileAction.java


editProfile.jsp


While trying to load the page I am getting the following error:


[ February 19, 2008: Message edited by: Mohammad Akon ]

[ February 19, 2008: Message edited by: Mohammad Akon ]
[ February 19, 2008: Message edited by: Mohammad Akon ]
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8877
    
    8

javax.servlet.ServletException: javax.servlet.jsp.JspException: Exception creating bean of class com.admin.EditProfileForm: java.lang.NullPointerException


This line in the stack trace says you had a null pointer exception in EditProfileForm. You didn't give us enough of the stack trace to see the source line so I can't tell you exactly where it is, but the problem is in your code.


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Intilization of form data