Which lib to open and view office file on browser

Hi all,when I receive a stream of file from server. How I can open and view this file on browser?My suggest: catch a stream and use library to open office file on browser, but I don't know which lib to do this.Thanks
[245 byte] By [musica] at [2007-11-27 7:08:26]
# 1

I'm confused, you're coding for the server-side, with JSP/servlets aren't you? So how can you intercept the stream at the browser? That'll be beyond your code.

And anyway, if you set the MIME types and set the content for the response, the browser itself will decide and prompt the user for handling the file.

If on the other hand, you want to open a file on the server and send the contents of that to the browser, you can look into Apache POI (http://poi.apache.org/) for handling Excel, Word and PowerPoint documents.

nogoodatcodinga at 2007-7-12 18:59:56 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
I mean which tool for view office file on client. (ex: applet)Thanks
musica at 2007-7-12 18:59:56 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
Just set the content type according to the file extension. You may find the downloadFile() snippets at the bottom of http://balusc.xs4all.nl/srv/dev-jep-pdf.html useful. You don't need special stuff. Just let the client operating system handle it, as usual.
BalusCa at 2007-7-12 18:59:56 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
I mean: We will receive a stream and must control it!. Open this office file by a applet exampleThanks
musica at 2007-7-12 18:59:56 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5
I mean: We will receive a stream and must control it!. Open this office file by a applet exampleThanks
musica at 2007-7-12 18:59:56 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...