You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Carlos <li...@lpis.com> on 2001/04/06 10:55:49 UTC

generating a excel page in the browser

in a jsp page if i put:
<%@page contentType="application/vnd.ms-excel"%>
the browser shows me a excel page.
but there is a problem. It show me a jsp page if i say to it for shown and
not to save.
when i want to see this page it asks me if i want to save or show the page.
What must i to write in the jso page for showing the excel page without
asking for saving?
thanks
Carlos


RE: generating a excel page in the browser

Posted by Danny Angus <da...@thought.co.uk>.
>
> IE4+ & Excel are quite good at picking up other file formats,
> such as CSV
> TAB etc,

I forgot to point out that as these are type text/plain you wont be prompted
to save, and excel will spot the filename extension.


RE: generating a excel page in the browser

Posted by Danny Angus <da...@thought.co.uk>.
you cant affect this behaviour, if you want to simply display in the
browser, then your user has to have elected not to be prompted for this MIME
type.
 :-(

IE4+ & Excel are quite good at picking up other file formats, such as CSV
TAB etc, and the best way of all (to get generated sheets into excel) is to
use excel as the browser, by typeing a URL into the File->Open dialogue box,
at the filename field.
Then deliver the M$ HTML format, generated by your webbapp, and you can
generate all the rich functionality of Excel workbooks, including
multiple-sheets, and VB macros.
You can create a return path functions in your macros to build up two way
traffic with the server.

Its an awsome effect when people see it for the first time.

danny


> What must i to write in the jso page for showing the excel
> page without
> asking for saving?
> thanks
> Carlos
>