I\'m using the PHPExcel library to read an Excel file and perform processing on it. I want to loop through each worksheet. I checked the documentation and all I could find was
I think you can do this. Increment the active sheet until there aren't any left, then do what you want with each one:
setReadDataOnly(true);
$objPHPExcel = $objReader->load("test.xlsx");
$i = 0;
while ($objPHPExcel->setActiveSheetIndex($i)){
$objWorksheet = $objPHPExcel->getActiveSheet();
//now do whatever you want with the active sheet
...
$i++;
}
...
?>