I'm trying to get a Date input from a jsp page and store it in the
database for my struts application.
And this is the error i'm getting :
java.lang.IllegalArgumentException: argument type mismatch
the tag that i have is used :
<html:text property="invoiceDate" styleId="textdate" readonly="true"
size="28" value="${sellingInvoice.invoiceDate}"/>
And here is my formbean
public class SellingInvoiceForm extends ActionForm {
private String invoiceDate;
public String getInvoiceDate() {
.................
}
public void setInvoiceDate(String invoiceDate) {
..............
}
}
and the DTO
public class SellingInvoice {
private Date invoiceDate;
public Date getInvoiceDate() {
.................
}
public void setInvoiceDate(Date invoiceDate) {
..............
}
}
IS both the DTO and the bean are declared correctly? and if so, what
code should i write in the getters and setters for both of them so
that my code can goes fine without this error?