text: public ChartSubstreamRecordAggregate(RecordStream rs){_bofRec = (BOFRecord)rs.GetNext();List<RecordBase> temp = new List<RecordBase>();while (rs.PeekNextClass() != typeof(EOFRecord)){Type a = rs.PeekNextClass();if (PageSettingsBlock.IsComponentRecord(rs.PeekNextSid())){if (_psBlock != null){if (rs.PeekNextSid() == HeaderFooterRecord.sid){_psBlock.AddLateHeaderFooter((HeaderFooterRecord)rs.GetNext());continue;}throw new InvalidDataException("Found more than one PageSettingsBlock in chart sub-stream");}_psBlock = new PageSettingsBlock(rs);temp.Add(_psBlock);continue;}temp.Add(rs.GetNext());}_recs = temp;Record eof = rs.GetNext(); if (!(eof is EOFRecord)){throw new InvalidOperationException("Bad chart EOF");}}