public FtrHeader(RecordInputStream in1) { recordType = in1.ReadShort(); grbitFrt = in1.ReadShort(); reserved = new byte[8]; in1.Read(reserved, 0, 8); }
public OldSheetRecord(RecordInputStream in1) { field_1_position_of_BOF = in1.ReadInt(); field_2_visibility = in1.ReadUByte(); field_3_type = in1.ReadUByte(); int field_4_sheetname_length = in1.ReadUByte(); field_5_sheetname = new byte[field_4_sheetname_length]; in1.Read(field_5_sheetname, 0, field_4_sheetname_length); }
public OldSheetRecord(RecordInputStream in1) { field_1_position_of_BOF = in1.ReadInt(); field_2_visibility = in1.ReadUByte(); field_3_type = in1.ReadUByte(); int field_4_sheetname_length = in1.ReadUByte(); field_5_sheetname = new byte[field_4_sheetname_length]; in1.Read(field_5_sheetname, 0, field_4_sheetname_length); }
/** * @param in the RecordInputstream to read the record from */ public OldStringRecord(RecordInputStream in1) { sid = in1.Sid; if (in1.Sid == biff2_sid) { field_1_string_len = (short)in1.ReadUByte(); } else { field_1_string_len = in1.ReadShort(); } // Can only decode properly later when you know the codepage field_2_bytes = new byte[field_1_string_len]; in1.Read(field_2_bytes, 0, field_1_string_len); }
/** * @param in the RecordInputstream to read the record from */ public OldStringRecord(RecordInputStream in1) { sid = in1.Sid; if (in1.Sid == biff2_sid) { field_1_string_len = (short)in1.ReadUByte(); } else { field_1_string_len = in1.ReadShort(); } // Can only decode properly later when you know the codepage field_2_bytes = new byte[field_1_string_len]; in1.Read(field_2_bytes, 0, field_1_string_len); }
/** * @param in the RecordInputstream to read the record from */ public OldLabelRecord(RecordInputStream in1) : base(in1, in1.Sid == biff2_sid) { if (IsBiff2) { field_4_string_len = (short)in1.ReadUByte(); } else { field_4_string_len = in1.ReadShort(); } // Can only decode properly later when you know the codepage field_5_bytes = new byte[field_4_string_len]; in1.Read(field_5_bytes, 0, field_4_string_len); if (in1.Remaining > 0) { logger.Log(POILogger.INFO, "LabelRecord data remains: " + in1.Remaining + " : " + HexDump.ToHex(in1.ReadRemainder()) ); } }
/** * @param in the RecordInputstream to read the record from */ public OldLabelRecord(RecordInputStream in1) : base(in1, in1.Sid == biff2_sid) { if (IsBiff2) { field_4_string_len = (short)in1.ReadUByte(); } else { field_4_string_len = in1.ReadShort(); } // Can only decode properly later when you know the codepage field_5_bytes = new byte[field_4_string_len]; in1.Read(field_5_bytes, 0, field_4_string_len); if (in1.Remaining > 0) { logger.Log(POILogger.INFO, "LabelRecord data remains: " + in1.Remaining + " : " + HexDump.ToHex(in1.ReadRemainder()) ); } }
/** * Read hyperlink from input stream * * @param in the stream to Read from */ public HyperlinkRecord(RecordInputStream in1) { try { rwFirst = in1.ReadShort(); rwLast = in1.ReadUShort(); colFirst = in1.ReadShort(); colLast = in1.ReadShort(); // 16-byte GUID guid = new byte[16]; in1.Read(guid, 0, guid.Length); label_opts = in1.ReadInt(); link_opts = in1.ReadInt(); if ((link_opts & HLINK_LABEL) != 0) { int label_len = in1.ReadInt(); label = in1.ReadUnicodeLEString(label_len); } if ((link_opts & HLINK_URL) != 0) { moniker = new byte[16]; in1.Read(moniker, 0, moniker.Length); if (Arrays.Equals(URL_MONIKER, moniker)) { int len = in1.ReadInt(); address = in1.ReadUnicodeLEString( (len - URL_TAIL.Length)/2); //minus the length of tail tail = in1.ReadRemainder(); } else if (Arrays.Equals(FILE_MONIKER, moniker)) { file_opts = in1.ReadShort(); int len = in1.ReadInt(); byte[] path_bytes = new byte[len]; in1.Read(path_bytes, 0, path_bytes.Length); address = Encoding.UTF8.GetString(path_bytes); tail = in1.ReadRemainder(); } } else if ((link_opts & HLINK_PLACE) != 0) { int len = in1.ReadInt(); address = in1.ReadUnicodeLEString(len); } } catch (IOException) { throw; } }