Blank.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Text;
  4. using System.Runtime.InteropServices;
  5. using Biff8Excel.Interfaces;
  6. namespace Biff8Excel.Records
  7. {
  8. [StructLayoutAttribute(LayoutKind.Sequential, CharSet = CharSet.Auto, Pack = 1)]
  9. struct RecordBlank
  10. {
  11. public ushort opcode; // 0x201;
  12. public ushort length; // 0x6;
  13. public ushort Row;
  14. public ushort Column;
  15. public ushort CellStyle;
  16. }
  17. internal class Blank : IRecords
  18. {
  19. RecordBlank blank;
  20. public Blank()
  21. {
  22. blank.opcode = 0x201;
  23. blank.length = 0x6;
  24. }
  25. public ushort Row
  26. {
  27. set { blank.Row = value; }
  28. }
  29. public ushort Column
  30. {
  31. set { blank.Column = value; }
  32. }
  33. public ushort CellStyle
  34. {
  35. set { blank.CellStyle = value; }
  36. }
  37. #region IRecords ³ÉÔ±
  38. public byte[] GetByte()
  39. {
  40. return Globals.GetStructToBytes(blank);
  41. }
  42. #endregion
  43. }
  44. }