In this tutorial I'll use the project structure that we created for the other tutorial. This project contains the POI jarW file in its classpathW. We will create a class that reads in data from an Excel file and displays it. The Excel file that we will use is the 'poi-test.xls' file that we previously created.

The poi-test.xls file is located at the root level of our project and is shown here:

The PoiReadExcelFile class will read in the 'poi-test.xls' file into an HSSFWorkbook object. The 'POI Worksheet' will then be read into an HSSFWorksheet object, and then the values within the A1, B1, C1, and D1 cells will be read and displayed to standard output.