How to know the type of a sheet in workbook?

Topics: Developer Forum, Project Management Forum, User Forum
May 8, 2013 at 1:43 PM
In an Excel workbook there can be 2 or more type of sheet, for example worksheet and chart as a sheet. I am trying the following code:
require_once 'plug-ins/phpexcel/PHPExcel.php';
$objPHPExcel = new PHPExcel_Reader_Excel2007();
{   $objPHPExcel = $objPHPExcel->load('excel-uploads/Book3.xls');
    $prodData = $objPHPExcel->getActiveSheet()->toArray();
catch(Exception $e)
{   if($e->getMessage() == 'ZipArchive library is not enabled')
        echo "Incorrect file format";
        echo 'Error: '.$e->getMessage();
Book3.xls has only one sheet and it is a chart sheet. If the above code is executed, the following error is occurring:
Fatal error: Class 'ZipArchive' not found in [path]\plug-ins\phpexcel\PHPExcel\Reader\Excel2007.php on line 497

So, what to do to know the type of the sheet or what is the workaround for this problem? And also, why this error is not getting caught in the try-catch block?