• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

BeanUtils.populate: multipart/form-data and "html:select" issues

 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I am getting the following error in my app:

javax.servlet.ServletException: BeanUtils.populate
at rg.apache.struts.util.RequestUtils.populate(RequestUtils.java:1254)
....
ROOT CAUSE
java.lang.IllegalArgumentException: argument type mismatch
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
...

In the JSP page, I am usign enctype="multipart/form-data" and I found some information about some known issues using <html:select> tag as well as nested tags. So I am wondering if there is a know issue with enctype="multipart/form-data" as well.At the begining, I thought the problem was the <html:select> so threw it away for testing puposes but I am still getting the error.

I already checked my ActionForm, validation.xml, Action implementation class, and I found nothing.

Any Idea on /advice on this?


Thanks in advance guys!





Here you have the ActionForm implementation

 
pie sneak
Posts: 4727
Mac VI Editor Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My guess is that it doesn't like the Long. Try changing that to a String and see what happens.
 
Jose Ortuno
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Marc thanks for writing,

I try changing the attibute to String and didn't work either. Actually, I have another page with Long attibutes that works just fine.

I lean towards the "multipart/form-data" which is the sole difference I an see.

Cheers,

Josel
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic