SpssFootnotes Class (Python)

The SpssFootnotes class provides access to all of the footnotes contained in a pivot table. The index of a footnote does not correspond to the footnote marker but to the order of their references in the table. The index is returned when you insert a new footnote.

You get an SpssFootnotes object from the FootnotesArray method of an SpssPivotTable object, as in:

SpssFootnotes = SpssPivotTable.FootnotesArray()

An SpssFootnotes object is also returned by the GetReferredFootnotesAt method of an SpssDataCells or SpssLabels object. The footnote collection thus returned contains only the footnotes referred to by the specified data cell or label. The indexes for the returned collection are in the ordinal order of the references in the referring cell. IBM® SPSS® Statistics does not provide a method to go from a footnote referred to by a cell to the same footnote contained in the footnote array of the table.

Example

This example assumes that PivotTable is an SpssPivotTable object and sets the background color to yellow for all data cells that have footnotes.

Footnotes = PivotTable.FootnotesArray()
PivotTable.ClearSelection() 
for i in range(Footnotes.GetCount()):
    Footnotes.SelectCellAt(i)
PivotTable.SetBackgroundColor(65535)