You are here

private function PHPExcel_Reader_Excel5::_readFormat in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Reader/Excel5.php \PHPExcel_Reader_Excel5::_readFormat()

* FORMAT * * This record contains information about a number format. * All FORMAT records occur together in a sequential list. * * In BIFF2-BIFF4 other records referencing a FORMAT record * contain a zero-based index into this list. From BIFF5 on * the FORMAT record contains the index itself that will be * used by other records. * * -- "OpenOffice.org's Documentation of the Microsoft * Excel File Format"

1 call to PHPExcel_Reader_Excel5::_readFormat()
PHPExcel_Reader_Excel5::load in vendor/phpoffice/phpexcel/Classes/PHPExcel/Reader/Excel5.php
* Loads PHPExcel from file * *

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Reader/Excel5.php, line 1970

Class

PHPExcel_Reader_Excel5
PHPExcel_Reader_Excel5

Code

private function _readFormat() {
  $length = self::_GetInt2d($this->_data, $this->_pos + 2);
  $recordData = $this
    ->_readRecordData($this->_data, $this->_pos + 4, $length);

  // move stream pointer to next record
  $this->_pos += 4 + $length;
  if (!$this->_readDataOnly) {
    $indexCode = self::_GetInt2d($recordData, 0);
    if ($this->_version == self::XLS_BIFF8) {
      $string = self::_readUnicodeStringLong(substr($recordData, 2));
    }
    else {

      // BIFF7
      $string = $this
        ->_readByteStringShort(substr($recordData, 2));
    }
    $formatString = $string['value'];
    $this->_formats[$indexCode] = $formatString;
  }
}