Optional
behaviorAdditional metadata about the function's behavior or requirements.
Optional
contextDescribes the execution context required by the function.
Contexts fall into two categories:
Macro contexts: Used by macro-style functions to access parts of the document or selection:
'Workbook'
: The entire workbook'Sheet'
: A single sheet'Range'
: A selected sheet range'Ranges'
: Multiple selected rangesCalculation context: Used by formula functions like OFFSET
or INDIRECT
that need access to evaluation position or sheet metadata during calculation.
This context is available in headless or worker environments.
execute
.IFunction.Calculation
then the function must return a value.IFunction.Calculation
then the function must return void
or a cleanup function.Named of the actual function in code.
The unique identifier for the function. It has a number of rules:
Optional
parametersAn array of Parameter
objects describing the function's parameters.
Optional
returnMetadata describing the type and dimensionality of the return value.
Contains metadata about a function declaration, including its name, return type, parameters, and additional documentation.