File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error while dowloading excel using weblogic server

 
Navaneetha Krishnan Sathasivam
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Coders,

I am generating the report in xlsx extension using weblogic 9.2.3 server and when i download tha excel file in client side i got the error like

"Excel cannot open the file 'filename.xlsx' because the file format or file extension is not valid. Verify the file has not been corrupted and that the file extension'matches the file format of the file."

The same code run perfectly in tomcat6.0 but if i run in weblogic 9.2.3 and i got the above specified error.


Please let me know if anyone knows the solution.

Thanks In Advance :)
 
anandraj tadkal
Ranch Hand
Posts: 98
Oracle Redhat
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Mime type for Xlsx is different from Xls. You can try putting the below entry in web.xml.

<mime-mapping>
<extension>xlsx</extension>
<mime-type>application/vnd.openxmlformats-officedocument.spreadsheetml.sheet</mime-type>
</mime-mapping>

Regards,
Anandraj
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic