commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kristine Weissbarth <kristine.weissba...@sourcepark.de>
Subject Re: fileUpload NullPointerException
Date Mon, 14 Jul 2003 09:11:03 GMT
hi,

I do not really understand why but with DiskFileUpload instead of
FileUpload it works.Thank you very much.

Kristine.



Am Fre, 2003-07-11 um 20.26 schrieb Martin Cooper:
> "Kristine Weissbarth" <kristine.weissbarth@sourcepark.de> wrote in message
> news:1057925436.587.47.camel@phoenix...
> > hi,
> >
> > I'm trying to get a servlet running which processes my fileUpload with
> > commons-fileUpload following the example on the website. But I always
> > get the following NullPointerException although the request is not null:
> 
> It looks like you haven't configured a file item factory. Which class are
> you instantiating for your upload handler (i.e. what type is 'upload' in
> your code)? You probably want to be using DiskFileUpload unless you're doing
> something special.
> 
> --
> Martin Cooper
> 
> 
> >
> > java.lang.NullPointerException
> > at
> org.apache.commons.fileupload.FileUploadBase.createItem(FileUploadBase.java:
> 507)
> > at
> org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase.jav
> a:390)
> > at de.sourcepark.fileUpload.uploadServlet.doPost(uploadServlet.java:107)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
> > ...
> >
> > The problem seems to be in the parseRequest method within the doPost of my
> servlet (= uploadServlet.java:107):
> >
> > List items = upload.parseRequest(request);
> >
> >
> > I cannot find the problem and either the solution. I guess it should be
> something trivial but I cannot find it.
> > Do you have a suggestions?
> >
> > Thanks.
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
> 


Mime
View raw message