# ClearResultsBuffer

Clears any buffered results from a factory protocol results buffer after a specified event. When the function Functions are tools that are available in Spreadsheet for processing and analyzing acquisitions or other results. You can add functions to your Spreadsheet job to create tool chains and produce results for specific applications. receives the specified event, the following occurs:

- All the results queued in the results buffer are removed (if results buffering is enabled).
- The current results being reported over the currently enabled factory protocol are cleared (including the result ID, result code and all result data).
- The Results Valid bit is cleared.

After the ClearResultsBuffer function executes, additional results can be queued, using the WriteResultsBuffer function.

Note: The function returns a 1 while the reset is occurring. In a steady state, the function returns a 0, indicating it is not currently resetting. The function returns ERR if the input parameter is invalid.
Inputs

The ClearResultsBuffer function has the following syntax:

ClearResultsBuffer(Event)

See the table for a description of the available parameters.

Parameter | Description
Event | Specifies the spreadsheet event that triggers the data to be cleared from the results buffer. This parameter needs to refer to any event with a timestamp, for example, one of the following: A cell containing an Event function. A cell containing a Button function.

Outputs

Returns | A value of 1, or #ERR if the input parameter is invalid.