This is my EmployeeList.jsp
======================================================================
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html:html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>List of Employee</title>
</head>
<body>
<table border="1" cellpadding="1" cellspacing="1" align="center">
<tr>
<th>Test header</th>
</tr>
<tr>
<logic:iterate id="result"name="EmployeeForm"property="empset">
<td><bean:write name="result"property="firstName"ignore="true"/></td>
<td><bean:write name="result"property="middleName"ignore="true"/></td>
<td><bean:write name="result"property="lastName"ignore="true"/></td>
<td><bean:write name="result"property="address"ignore="true"/></td>
<td><bean:write name="result"property="birth"ignore="true"/></td>
<td><bean:write name="result"property="phoneNo"ignore="true"/></td>
<td><bean:write name="result"property="position"ignore="true"/></td>
<td><bean:write name="result"property="salary"ignore="true"/></td>
</logic:iterate>
</tr>
<tr>
<td><a href="pages/MainForm.jsp"> <html:button value="Back to Main Menu" property="back"/> </a></td>
</tr>
</table>
</body>
</html:htm
=========================================================================
This is my Form Class(EmployeeForm.java)
public class EmployeeForm extends ActionForm {
private static final long serialVersionUID = 1L;
public String firstName = "";
public String middleName = "";
public String lastName = "";
public String address = "";
public String birth = "";
public String phoneNo = "";
public String position = "";
public String salary = "";
Set<Employee> empset = new HashSet<Employee>();
public String getFirstName() {
return firstName;
}
public void setFirstName(String firstName) {
this.firstName = firstName;
}
public String getMiddleName() {
return middleName;
}
public void setMiddleName(String middleName) {
this.middleName = middleName;
}
public String getLastName() {
return lastName;
}
public void setLastName(String lastName) {
this.lastName = lastName;
}
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
public String getBirth() {
return birth;
}
public void setBirth(String birth) {
this.birth = birth;
}
public EmployeeForm() {
super();
// TODO Auto-generated constructor stub
}
public String getPhoneNo() {
return phoneNo;
}
public void setPhoneNo(String phoneNo) {
this.phoneNo = phoneNo;
}
public String getPosition() {
return position;
}
public void setPosition(String position) {
this.position = position;
}
public String getSalary() {
return salary;
}
public void setSalary(String salary) {
this.salary = salary;
}
public Set<Employee> getEmpset() {
return empset;
}
public void setEmpset(Set<Employee> empset) {
this.empset = empset;
}
}
=====================================================================
the first 4 bean write execute well (firstname,middlename,lastname,address)
from birth up to salary i got an error (No getter method for property birth of bean result)