github.com/shakinm/xlsReader@v0.9.12/xls/record/biff.go (about) 1 package record 2 3 /* 4 Record Data — BIFF8 5 6 Offset Field Name Size Contents 7 -------------------------------------------- 8 4 vers 2 Version number: 9 =0600 for BIFF8 10 6 dt 2 Substream type: 11 0005h = Workbook globals 12 0006h = Visual Basic module 13 0010h = Worksheet or dialog sheet 14 0020h = Chart 15 0040h = Excel 4.0 macro sheet 16 0100h = Workspace file 17 8 rupBuild 2 Build identifier (=0DBBh for Excel 97) 18 10 rupYear 2 Build year (=07CCh for Excel 97) 19 12 bfh 4 File history flags 20 16 sfo 4 Lowest BIFF version (see text) 21 22 23 The rupBuild and rupYear fields contain numbers that identify the version (build) 24 of Excel that wrote the file. If you write a BIFF file, you can use the BiffView utility 25 to determine the current values of these fields by examining a BOF record in a 26 workbook file. 27 The sfo structure contains the earliest version ( vers structure) of Excel that can read all 28 records in this file. 29 30 The bfh structure contains the following flag bits: 31 32 Bits Mask Flag Name Contents 33 -------------------------------------------- 34 0 00000001h fWin =1 if the file was last edited by Excel for Windows 35 1 00000002h fRisc =1 if the file was last edited by Excel on a RISC platform 36 2 00000004h fBeta =1 if the file was last edited by a beta version of Excel 37 3 00000008h fWinAny =1 if the file has ever been edited by Excel for Windows 38 4 00000010h fMacAny =1 if the file has ever been edited by Excel for the Macintosh 39 5 00000020h fBetaAny =1 if the file has ever been edited by a beta version of Excel 40 7–6 000000C0h (Reserved) Reserved; must be 0 (zero) 41 8 00000100h fRiscAny =1 if the file has ever been edited by Excel on a RISC platform 42 31–9 FFFFFE00 (Reserved) Reserved; must be 0 (zero) 43 44 */ 45 var FlagBIFF8 = []byte{0x00, 0x06} 46 47 type biff8 struct { 48 vers [2]byte 49 dt [2]byte 50 rupBuild [2]byte 51 rupYear [2]byte 52 bfh [4]byte 53 sfo [4]byte 54 } 55 56 var FlagBIFF5 = []byte{0x00, 0x05} 57 58 type biff5 struct { 59 vers [2]byte 60 dt [2]byte 61 rupBuild [2]byte 62 rupYear [2]byte 63 }