07.05.2014 Views

The Microsoft Excel File Format - OpenOffice.org

The Microsoft Excel File Format - OpenOffice.org

The Microsoft Excel File Format - OpenOffice.org

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

4.7 Cell Table and Row Blocks<br />

• Finding Cells in a Row Block (BIFF5-BIFF8)<br />

In BIFF5-BIFF8 the DBCELL record (➜5.29) follows the cell records and contains exactly the stream offsets which the<br />

ROW records would contain in BIFF2-BIFF4. In the DBCELL record this offset list is lead by an offset to the first<br />

ROW record in this Row Block. This offset is a positive value, although it points backwards to an earlier stream<br />

position. While no record would occur in BIFF2-BIFF4 for empty Row Blocks, in BIFF5-BIFF8 a DBCELL record is<br />

written for each and every Row Block.<br />

Example: A Row Block contains one cell per row in the rows 10, 11, and 12. Row 13 is not used, the height of<br />

row 14 is changed (but it does not contain a cell). Row 15 contains a cell again. In this example, the first column<br />

shows the absolute stream position of each record.<br />

07B2 H ROW Row = 10 (Record size with header = 0014 H )<br />

07C6 H ROW Row = 11<br />

07DA H ROW Row = 12<br />

07EE H ROW Row = 14 (no record for row 13)<br />

0802 H ROW Row = 15<br />

0816 H RK Address = A10<br />

0824 H NUMBER Address = A11<br />

0836 H RK Address = A12<br />

0844 H NUMBER Address = A15<br />

0856 H DBCELL Offset to first ROW record = 00A4 H<br />

Offsets = 0050 H , 000E H , 0012 H , 000E H , 0000 H<br />

<strong>The</strong> base position for the calculation of all cell record positions is the start of the second ROW record, 07C6 H . It<br />

is calculated from the position of the DBCELL record (contained in the INDEX record, ➜4.7.5), the first offset<br />

this DBCELL record contains, and the size of the first ROW record:<br />

0856 H - 00A4 H + 0014 H = 07B2 H + 0014 H = 07C6 H .<br />

<strong>The</strong> calculation of the cell record positions works equally to the example for BIFF2-BIFF4 above (using 07C6 H<br />

as base stream position).<br />

If the size of all cell records of a row exceeds FFFF H , the respective position in the DBCELL record will contain the<br />

offset 0000 H . From this point on, the offsets cannot be used anymore to calculate stream positions.<br />

93

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!