commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Bowen <>
Subject copyProperties with FormFile or Date
Date Wed, 24 Nov 2004 17:12:23 GMT
I had a problem a while ago when I copied from a bean
(a Torque object) to another bean (Action Form) that
had a Date field, using copyProperties(). It would
crash, with an "argument type mismatch" error. I
played around with it for quite a while, reading about
how you have to register your Date types for it to
work, etc. But I never got it to work, and since the
objects I was using only had a few fields, I just
copied them by hand from the Torque object to the

But it's come back to bite me in the butt. Now I have
another Form with a FormFile field and it crashes for
the same reason "argument type mismatch", when calling
copyProperties(). I am not sure if this only happens
when the Form File field loaded from the database has
no data in it (thus not being able to copy properly)
or if it always crashes ...

My question is ... well, why doesn't copyProperties()
take care of this? Or, if it does, what am I doing
wrong? And, if there is no "fix" is there an easier
way to copy SOME and not ALL of the properties of a
Bean? It was no problem with my first bean, it had 3
fields, but this one has over 30!

Many thanks in advance.

Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message