12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- using System;
- using System.Collections.Generic;
- using System.Text;
- using System.Runtime.InteropServices;
- using Biff8Excel.Interfaces;
- namespace Biff8Excel.Records
- {
- [StructLayoutAttribute(LayoutKind.Sequential, CharSet = CharSet.Auto, Pack = 1)]
- struct RecordBOF
- {
- public ushort opcode; // 0x809;
- public ushort length; // 0x10;
- public ushort version; // 0x600;
- public EnumBofTypes type;
- public ushort build; // 0x27F3;
- public ushort year; // 0x7CD; //1997
- public uint history; // 0x40C9;
- public uint rversion; // 0x106;
- }
- internal enum EnumBofTypes : ushort
- {
- bofWorkbook = 0x5,
- bofWorkSheet = 0x10
- }
- internal class BOF : IRecords
- {
- RecordBOF bof;
-
- public BOF()
- {
- bof.opcode = 0x809;
- bof.length = 0x10;
- bof.type = EnumBofTypes.bofWorkbook ;
- bof.version = 0x600;
- bof.year = 0x7CD;
- bof.build = 0x27F3;
- bof.history = 0x40C9;
- bof.rversion = 0x106;
- //bof.build = 0x19A0;
- //bof.history = 0xC0;
- //bof.rversion = 0x306;
- }
- internal EnumBofTypes DataType
- {
- set{ bof.type = value;}
- }
- internal ushort Id
- {
- get{return bof.opcode ;}
- }
-
- #region IRecords ³ÉÔ±
- public byte[] GetByte()
- {
- return Globals.GetStructToBytes(bof);
- }
- #endregion
- }
- }
|