Class: DateModeRecord

Inherits:
BiffRecord show all
Defined in:
lib/surpass/biff_record.rb

Overview

This record specifies the base date for displaying date values. All dates are stored as count of days past this base date. In BIFF2-BIFF4 this record is part of the Calculation Settings Block. In BIFF5-BIFF8 it is stored in the Workbook Globals Substream.

Record DATEMODE, BIFF2-BIFF8:

Offset Size Contents 0 2 0 = Base is 1899-Dec-31 (the cell = 1 represents 1900-Jan-01)

1 = Base is 1904-Jan-01 (the cell = 1 represents 1904-Jan-02)

Constant Summary collapse

RECORD_ID =
0x0022

Constants inherited from BiffRecord

BiffRecord::BIFF_LIMIT, BiffRecord::CONTINUE_RECORD_ID

Instance Attribute Summary

Attributes inherited from BiffRecord

#record_data

Instance Method Summary collapse

Methods inherited from BiffRecord

#record_header, #to_biff

Constructor Details

#initialize(boolean) ⇒ DateModeRecord

Returns a new instance of DateModeRecord.



441
442
443
# File 'lib/surpass/biff_record.rb', line 441

def initialize(boolean)
  @record_data = boolean ? [1].pack('v') : [0].pack('v')
end