File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes getParameter() - Incompatible Type Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "getParameter() - Incompatible Type" Watch "getParameter() - Incompatible Type" New topic

getParameter() - Incompatible Type

JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309
I am using the request.getParameter(); to get a file. This file is of the org.apache.struts.upload.FormFile type. I got this compilation error: incompatible types
found : java.lang.String
required: org.apache.struts.upload.FormFile
FormFile file = request.getParameter( "theFile" );

What should I do if I cannot use the getParameter() method?
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
have a look here
I agree. Here's the link:
subject: getParameter() - Incompatible Type
It's not a secret anymore!