Reading Different Worksheets from one file

Topics: User Forum
Apr 2, 2013 at 7:50 AM

The excel spreadsheet file that i have can have anywhere between 1 and 12 worksheet's, what function (group of functions) would i use to get phpexcel to move from worksheet to worksheet, it is probably going to be really obvious or i have just missed it completely :s

Thanks in advance :)
Apr 2, 2013 at 8:50 AM
Edited Apr 2, 2013 at 9:01 AM
PHPExcel::getSheet($Index) // zero based

If you need to iterate for each sheet, you have a Worksheet Iterator, see Tests\28iterator.php for an example.