Rafael Taboada wrote the following on 7/11/2005 5:34 PM:
Michael, it didn't work..
What didn't work? You still got validation when it was set to false?
(Also just a side note, it's good practice to move all the JDBC
Connection stuff to another class other than your Action. You might be
intending to do that later, so not meaning to critique too soon.)
My Action class is:
public class ColorAction extends DispatchAction {
public ActionForward buscarColor(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response)
throws Exception {
ColorForm colorForm = (ColorForm) form;
MySQLDAOFactory factory = new MySQLDAOFactory();
DataSource ds = getDataSource(request,Constantes.DATASOURCEKEY);
Connection conn = ds.getConnection();
Collection collResultado;
try {
ColorDAO colorDAO = factory.getColorDAO(conn);
colorForm.validate(mapping,request);
collResultado = colorDAO.findColorByDescripcion(
colorForm.getstrFiltroDescripcion());
}
finally {
conn.close();
}
colorForm.setlstResultado(collResultado);
return mapping.getInputForward();
}
....... //There are other methods
}
So, what is wrong????
I tried to use ValidatorActionForm instead of ValidatorForm... And of course
in my validator call my actionmapping like: "/Colores",
"/Colores?method=buscarColor"... But it doesn't work too...
How can I do???... THanks in advance...
When I turned off validate attribute... It doesn't validate anything... I'm
calling validate method in my action class but it doesn't work...
Where are you calling validate manually? I don't see you doing that in
the Action class you provided.
--
Rick
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]