title: PHPExcel function getHighestRow() is NOT working for .xls but working for .xlsx
body: <p>I am using <strong>PHPExcel</strong> to read its content based on no.of rows present.</p>
  
  <p>To find no.of rows I am using following function. </p>
  
  <pre><code>$objSheet-&gt;getHighestRow();
  </code></pre>
  
  <p>It is working fine for .xlsx files.</p>
  
  <p>But it is <strong>NOT</strong> working  in .xls.</p>
  
  <blockquote>
    <p>Fatal error: Call to a member function getHighestRow() on a non-object</p>
  </blockquote>
  
  <p>So how i can get no.of rows of excel ?</p>
  
  <p>PHP Code:</p>
  
  <pre><code>    set_include_path(get_include_path() . PATH_SEPARATOR . 'Classes/');
      /** PHPExcel_IOFactory */
      include 'www/PHPExcelReader/Classes/PHPExcel/IOFactory.php';
      include 'www/PHPExcelReader/Classes/PHPExcel/Classes/PHPExcel.php';
      try {
          $cacheMethod = PHPExcel_CachedObjectStorageFactory::cache_to_sqlite3;
          PHPExcel_Settings::setCacheStorageMethod($cacheMethod, $cacheSettings);
          $objReader = new PHPExcel_Reader_Excel2007();
          $objReader-&gt;setReadDataOnly(true);
          $objReader-&gt;setLoadSheetsOnly( array("Sheet1") );
          $objPHPExcel = $objReader-&gt;load($inputFileName);
          $objSheet = $objPHPExcel-&gt;getActiveSheet();
          $no_of_rows=$objSheet-&gt;getHighestRow();
          //echo "no_of_rows=$no_of_rows";
  </code></pre>
  
  <p>I want both xls &amp; .xlsx to be supported... Please guide me.</p>