2.5.133 FormulaValue

The FormulaValue structure specifies the current value of a formula. It can be a numeric value, a Boolean value, an error value, a string value, or a blank string value. If fExprO is not 0xFFFF, the 8 bytes of this structure specify an Xnum (section 2.5.342). If fExprO is 0xFFFF, this structure specifies a Boolean value, an error value, a string value, or a blank string value.


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

byte1

byte2

byte3

byte4

byte5

byte6

fExprO

byte1 (1 byte):  If fExprO is 0xFFFF, byte1 is an unsigned integer that specifies the formula value type and MUST be a value from the following table:

Value

Meaning

0x00

String value. The string value is stored in a String record that immediately follows this record.

0x01

Boolean value.

0x02

Error value.

0x03

Blank string value.

If fExprO is not 0xFFFF, byte1 specifies the first byte of the Xnum.

byte2 (1 byte):  If fExprO is 0xFFFF, byte2 is undefined and MUST be ignored. If fExprO is not 0xFFFF, byte2 specifies the second byte of the Xnum (section 2.5.342).

byte3 (1 byte):  The meaning of byte3 is specified in the following table:

Value

Meaning

fExprO is 0xFFFF and byte1 is 0x00

byte3 is undefined and MUST be ignored.

fExprO is 0xFFFF and byte1 is 0x01

byte3 specifies a Boolean value.

fExprO is 0xFFFF and byte1 is 0x02

byte3 specifies a BErr.

fExprO is 0xFFFF and byte1 is 0x03

byte3 is undefined and MUST be ignored.

fExprO is not 0xFFFF

byte3 specifies the third byte of the Xnum.

byte4 (1 byte):  If fExprO is 0xFFFF, byte4 is undefined and MUST be ignored. If fExprO is not 0xFFFF, byte4 specifies the fourth byte of the Xnum.

byte5 (1 byte):  If fExprO is 0xFFFF, byte5 is undefined and MUST be ignored. If fExprO is not 0xFFFF, byte5 specifies the fifth byte of the Xnum.

byte6 (1 byte):  If fExprO is 0xFFFF, byte6 is undefined and MUST be ignored. If fExprO is not 0xFFFF, byte6 specifies the sixth byte of the Xnum.

fExprO (2 bytes): If fExprO is 0xFFFF, this structure specifies a Boolean value, an error value, a string value, or a blank string value. If fExprO is not 0xFFFF, fExprO specifies the last two bytes of the Xnum.