2.4.271 SupBook

The SupBook record specifies a supporting link and specifies the beginning of a collection of records as defined by the Globals Substream ABNF.  The collection of records specifies the contents of an external workbook, DDE data source, or OLE data source.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

ctab

cch

virtPath (variable)

...

rgst (variable)

...

ctab (2 bytes):  An undefined field, a reserved field, or an unsigned integer that specifies the number of sheets in a referenced external workbook. The type and meaning of this field is dependent on the type of supporting link specified by the cch and virtPath fields, and is defined in the following table:

Type of supporting link specified by cch and virtPath

Meaning

Self-referencing

Undefined and MUST be ignored.

Same-sheet referencing

DDE data source referencing

OLE data source referencing

Reserved. MUST be 0x0000.

Add-in referencing

Reserved. MUST be 0x0001.

External workbook referencing

An unsigned integer that specifies the count of sheets in the referenced external workbook.

Unused

An unsigned integer that specifies the count of sheets in the external workbook formerly referenced by this supporting link, if this supporting link was an external workbook referencing type, when used. Otherwise, this value MUST be 0x0000.

cch (2 bytes): An unsigned integer that specifies a type of supporting link or specifies the length of the string in virtPath. MUST be a value from the following table:

Value

Meaning

0x0401

This record specifies a self-referencing supporting link.

0x3A01

This record specifies an add-in referencing type of supporting link. The names of all add-in functions implemented by XLL, or COM automation add-ins that are referenced by formulas in this workbook, MUST be specified in the ExternName records that follow this record.

0x0001 to 0x00ff (inclusive)

The type of supporting link specified by this record is specified by virtPath.  This value is the count of characters in virtPath.

virtPath (variable):  An XLUnicodeStringNoCch structure that specifies the type of supporting link and, if applicable, the target of that supporting link. This field MUST exist if and only if the value of cch is between 0x0001 and 0x00ff (inclusive). The length of the string in this field MUST be equal to cch. The contents of this field MUST be a value from the following table:

Value

Meaning

A single character of Unicode value 0x20 (SPACE)

This record specifies an unused supporting link. This supporting link MUST NOT be used by any external reference consumers.

A single character of Unicode value 0x00 (NULL)

This record specifies a same-sheet referencing type of supporting link.

A string that conforms to the OLE-link rule, as specified in VirtualPath

This record specifies a DDE data source referencing or an OLE data source referencing type of supporting link. The value of this field specifies the target of the supporting link.

A string that conforms to the virt-path rule, but does not conform to the ole-link rule, as specified in VirtualPath

This record specifies an external workbook referencing type of supporting link. The value of this field specifies the path and file name of the external workbook.

rgst (variable):  An array of XLUnicodeString structures that specify sheet names in the external workbook. This field MUST exist if and only if the supporting link type specified by cch and virtPath is external workbook referencing or unused. If this field exists, the number of elements in this array MUST be equal to ctab. The contents and meaning of this array are defined in the following table:

Type of supporting link

rgst value

External workbook referencing

An array of XLUnicodeString structures that specify the sheet names in the external workbook. Each element in this array MUST conform to the restrictions set on the stName field of the BoundSheet8 record.

Unused

An array of XLUnicodeString structures that provide placeholders for any XTI references to sheets in this unused supporting link. Each element in this array MUST be a string that contains a single character of Unicode value 0x20 (SPACE).