aspose file tools*
The moose likes Applets and the fly likes reading and displaying excel file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Applets
Bookmark "reading and displaying excel file" Watch "reading and displaying excel file" New topic
Author

reading and displaying excel file

Laura Williamson
Ranch Hand

Joined: Apr 28, 2004
Posts: 44
Hi - I have a simple applet that reads in from a text file and displays the values to the screen. Has anyone done this, but reading in from Excel file instead? Thanks
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39548
    
  27
I assume the file is on the server where the applet resides, and not on the client machine?

The Apache POI library can read Excel files. You would create an HSSFWorkbook object from the file input stream, and then use the getSheet method to obtain a reference to the sheet you want to display. The sheet's getRow method gives you a reference to a row of cells, from which you can call getCell to get the contents of any particular cell.


Ping & DNS - updated with new look and Ping home screen widget
Sandeep Chhabra
Ranch Hand

Joined: Aug 28, 2005
Posts: 340
Hi Ulf,

What about the powerpoint files.... Can we read them as well??


Regards<br />Sandy<br />[SCJP 5.0 - 75%]<br />[SCWCD 1.4 - 85%]<br />------------------<br />Tiger, Tiger burning bright,<br />Like a geek who works all night,<br />What new-fangled bit or byte,<br />Could ease the hacker's weary plight?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39548
    
  27
The POI library has limited support for PPT files as well (not nearly as good as the XLS support). Here's an introduction to what's possible.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: reading and displaying excel file
 
Similar Threads
Java - MsExcel - java
Amending a string value with Performance and Efficency in mind
opening excel application in browser
Excel file manipulation
CSV+truncate leading zero solution