Hello,

You can format colums in excel, separating each of your columns with a TAB.
Do you know how can I save an excel file to the disk with servlets?.

bye

Lorena

----- Original Message -----
From: Segador Corraliza, Jose Abel [EES/ES]
<[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, June 21, 2001 8:00 AM
Subject: Return an excel file to the clients


> Hello everybody!
>
>         I have the following code in a servlet, to send the clients data
in
> an excel file. The problem is that Explorer opens Excel but cannot
> interprets the data. What do I have to do to see them grouped by excel
> colums?
>
>         Thanks a lot.
>
> Abel S.
>
>         oCanalSalida = new PrintStream(response.getOutputStream());
>
>
response.setHeader("Content-Disposition","filename="+oValoresEstadisticas.ge
> tNombreEstadistica()+".enec");
>         response.setContentType("application/vnd.ms-excel");
>
>         while (itValoresEstadisticas.hasMoreElements() ) {
>           oCanalSalida.println
>
(oValorEstadistica.getFecha()+";"+oDecimalFormat.format(Float.parseFloat(oVa
> lorEstadistica.getValor())* oValoresEstadisticas.getFactor()));
>         }
>
>         oCanalSalida.close();
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to