Bookmark Topic Watch Topic
  • New Topic

Read excel file from form file tag?

 
chandana nalin
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Report post to moderator
How to get real path name using form file tag using servlet??
 
chandana nalin
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Report post to moderator


didnt support
 
chandana nalin
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Report post to moderator
java.io.FileNotFoundException: itemPriceListnew.xlsx (The system cannot find the file specified)
 
Tim Moores
Saloon Keeper
Posts: 3262
54
  • Mark post as helpful
  • send pies
  • Report post to moderator
In web apps you need to use absolute paths, not relative paths like the code uses here. What's more, the file name passed to the servlet is a client-side file or path, and thus of no use on the server.

As was pointed out to you yesterday, use a file upload library like Apache Commons FileUpload.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65530
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Report post to moderator
I've closed this topic so that the discussion can be continued in the original topic on file uploading.
 
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!