Shailesh,

The ssLocation + ssName is just the location and name of the excel file you
want to create.  I load these dynamically so that the user can specify the
location and name of the file.

Sorry for the confusion.

-Ethan

-----Original Message-----
From: Knepp, Ethan 
Sent: Thursday, May 29, 2003 10:35 AM
To: 'POI Users List'
Subject: RE: adding a speadsheet


Shailesh,

Below is the order in which I create a new workbook and add a sheet to it...

// create the output stream for the workbook
FileOutputStream out = new FileOutputStream(ssLocation + ssName);

// create a new workbook
HSSFWorkbook wb = new HSSFWorkbook();

// create a new sheet
HSSFSheet sheet = wb.createSheet();

After you create the sheet you can add rows and cells to it.  

Check the following link for a good examples:
http://jakarta.apache.org/poi/hssf/quick-guide.html

Hope this helps.
-Ethan

-----Original Message-----
From: Shailesh Ligade [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 29, 2003 10:31 AM
To: [EMAIL PROTECTED]
Subject: adding a speadsheet


Hello All,

I need to create excel file with many sheet. One of my java class, will
call bunch of classes, each returning a sheet, and then calling calls
will create workbook and able to add all the sheets to it. Is this
possible using POI? I didn't see any API for doing this. Sheet
constructors are protected, and I didn't find any way to add sheet to
workbook passing a sheet.

Thanks
SL

Reply via email to