Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

using forward slash in jsp to excel  RSS feed

 
arun ramk
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi Friends,

I am export data from stuts/jsp to excel by setting response as follows in Action class
response.setContentType("application/xls");
but when a data like "1/0" or "3/4" is sent to excel sheet , it considers it as date and converts in to date format like JAN-00
Please let me know how to handle this issue in excel.



Regards,
Arun.
 
karan wadhwani
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how you are setting data to excel?
check API there should be some method to set as numeric or as string..
 
arun ramk
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not using any API's like POI or jexcel.
just setting the content type to xls
response.setContentType("Application/xls"); in Struts/Action class....
The page displayed in table format in UI is converted to excel format thats it..........
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!