Win a copy of OCP Oracle Certified Professional Java SE 11 Programmer I Study Guide: Exam 1Z0-815 this week in the Programmer Certification forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Paweł Baczyński
  • Piet Souris
  • Vijitha Kumara

unable to downladmultiple file?

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have uploaded the files.But unable to download ......
Please help ....





Stack Trace


Please Reply..
Thanks in advance...
 
Bartender
Posts: 9588
13
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Purnendu Das wrote:



Why are you writing a file on the server? Why is the file's name "C:"??



Do you really have an input file named ""???
 
Priyanka Das
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Joe Ess wrote:

Purnendu Das wrote:



Why are you writing a file on the server? Why is the file's name "C:"??
That is just written.Not using that variable inside try block...........



Do you really have an input file named ""???
No I dont have..



 
Priyanka Das
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is my code inside try block....
Below code is working fine...


This is becoming Null..

I have one Question.
I have the file path and file name in database...and file is in server(webapps folder)....
can I get the Filedata through form file....
 
Joe Ess
Bartender
Posts: 9588
13
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Purnendu Das wrote:

Joe Ess wrote:

Purnendu Das wrote:



Why are you writing a file on the server? Why is the file's name "C:"??
That is just written.Not using that variable inside try block...........




You are using the path variable - to create a FileOutputStream. The exception you show says that cannot be done:


I have a good idea why this is happening (Tomcat's security configuration) but I'm asking why you are doing it in the first place.
 
Priyanka Das
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is my new code....




here I am getting NULL.

What I have to write here...



This is my stack trace..
 
They weren't very bright, but they were very, very big. Ad contrast:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!