I am using PHPExcel for import data from excel file. but I find some problems where the data was dynamically repeated per sheets and I wanted to take the last sheet to process. Is there any idea or method to get the highest sheet index ?
Get the total number of sheets:
$sheetCount = $excelObj->getSheetCount();
The last sheet index will be:
$lastSheet = $sheetCount - 1;