Represents a column in a [[WorksheetTable]].
Constructors
Section titled "Constructors"WorksheetTableColumn
new WorksheetTableColumn(a: WorksheetTable, b: number, c: number): WorksheetTableColumn Returns WorksheetTableColumn
Properties
Section titled "Properties"$t: Type filter
Section titled "filter"filter: Filter name: string sortCondition
Section titled "sortCondition"sortCondition: SortCondition totalFormula
Section titled "totalFormula"totalFormula: Formula totalLabel
Section titled "totalLabel"totalLabel: string Accessors
Section titled "Accessors"columnFormula
Section titled "columnFormula"Gets the formula associated with the data area of the column.
get columnFormula(): Formula Returns Formula
dataAreaRegion
Section titled "dataAreaRegion"Gets the [[WorksheetRegion]] which represents the region of cells in the data area of the column.
get dataAreaRegion(): WorksheetRegion Returns WorksheetRegion
headerCell
Section titled "headerCell"Gets the [[WorksheetCell]] which represents the header cell for the column. A WorksheetCell which represents the header cell for the column or null if the header row is not visible in the table.
get headerCell(): WorksheetCell Returns WorksheetCell
index
Section titled "index"Gets the 0-based index of the column in the owning [[WorksheetTable.columns]] collection. The 0-based index of the column in its collection or -1 if the column has been removed from the table.
get index(): number Returns number
table
Section titled "table"Gets the [[WorksheetTable]] to which the column belongs. The WorksheetTable to which the column belongs or null if the column has been removed from the table.
get table(): WorksheetTable Returns WorksheetTable
totalCell
Section titled "totalCell"Gets the [[WorksheetCell]] which represents the total cell for the column. A WorksheetCell which represents the total cell for the column or null if the totals row is not visible in the table.
get totalCell(): WorksheetCell Returns WorksheetCell
wholeColumnRegion
Section titled "wholeColumnRegion"Gets the [[WorksheetRegion]] which represents the region of cells in the whole column, including the header and total cells, if visible.
get wholeColumnRegion(): WorksheetRegion Returns WorksheetRegion
Methods
Section titled "Methods"applyAverageFilter
Section titled "applyAverageFilter"Applies an [[AverageFilter]] to the column.
applyAverageFilter(type: AverageFilterType): AverageFilter Parameters
- type:
AverageFilterTypeThe value indicating whether to filter in values below or above the average of the data range.
Returns AverageFilter
applyCustomFilter
Section titled "applyCustomFilter"Applies a [[CustomFilter]] to the column.
applyCustomFilter(condition: CustomFilterCondition): CustomFilter Parameters
- condition:
CustomFilterConditionThe condition which must pass for the data to be filtered in.
Returns CustomFilter
applyDatePeriodFilter
Section titled "applyDatePeriodFilter"Applies an [[DatePeriodFilter]] to the column.
applyDatePeriodFilter(type: DatePeriodFilterType, value: number): DatePeriodFilter Parameters
- type:
DatePeriodFilterTypeThe type of date period to filter in.
- value:
numberThe 1-based value of the month or quarter to filter in.
Returns DatePeriodFilter
applyFillFilter
Section titled "applyFillFilter"Applies a [[FillFilter]] to the column.
applyFillFilter(fill: CellFill): FillFilter Parameters
- fill:
CellFillA [[CellFill]] by which the cells should be filtered.
Returns FillFilter
applyFixedValuesFilter
Section titled "applyFixedValuesFilter"Applies a [[FixedValuesFilter]] to the column.
applyFixedValuesFilter(includeBlanks: boolean, calendarType: CalendarType, dateGroups: FixedDateGroup[]): FixedValuesFilter Parameters
- includeBlanks:
booleanThe value which indicates whether blank cells should be filtered in.
- calendarType:
CalendarTypeThe calendar type used to interpret values in the 'dateGroups' collection.
- dateGroups:
FixedDateGroup[]The collection of fixed date groups which should be filtered in.
Returns FixedValuesFilter
applyFontColorFilter
Section titled "applyFontColorFilter"Applies a [[FontColorFilter]] to the column.
applyFontColorFilter(fontColorInfo: WorkbookColorInfo): FontColorFilter Parameters
- fontColorInfo:
WorkbookColorInfoA [[WorkbookColorInfo]] which describes the font color by which the cells should be filtered.
Returns FontColorFilter
applyIconFilter
Section titled "applyIconFilter"Applies a [[IconFilter]] to the column.
applyIconFilter(iconSet: FormatConditionIconSet, iconIndex: number): IconFilter Parameters
- iconSet:
FormatConditionIconSetThe icon set containing the icon.
- iconIndex:
numberThe zero-based index of the icon in the set or null for 'NoCellIcon'.
Returns IconFilter
applyRelativeDateRangeFilter
Section titled "applyRelativeDateRangeFilter"Applies a [[RelativeDateRangeFilter]] to the column.
applyRelativeDateRangeFilter(offset: RelativeDateRangeOffset, duration: RelativeDateRangeDuration): RelativeDateRangeFilter Parameters
- offset:
RelativeDateRangeOffsetThe offset of relative filter. This combined with the 'duration' determines the full range of accepted dates.
- duration:
RelativeDateRangeDurationThe duration of the full range of accepted dates.
Returns RelativeDateRangeFilter
applyTopOrBottomFilter
Section titled "applyTopOrBottomFilter"Applies a [[TopOrBottomFilter]] to the column which will filter in the top 10 values in the list of sorted values.
applyTopOrBottomFilter(): TopOrBottomFilter Returns TopOrBottomFilter
applyYearToDateFilter
Section titled "applyYearToDateFilter"Applies a [[YearToDateFilter]] to the column.
applyYearToDateFilter(): YearToDateFilter Returns YearToDateFilter
areaFormats
Section titled "areaFormats"Gets the format for the specified area. An [[IWorksheetCellFormat]] instance describing the appearance of the specified area.
areaFormats(area: WorksheetTableColumnArea): IWorksheetCellFormat Parameters
- area:
WorksheetTableColumnAreaThe area for which to get the format.
Returns IWorksheetCellFormat
clearFilter
Section titled "clearFilter"Removes the filter from the column if one is applied.
clearFilter(): void Returns void
setColumnFormula
Section titled "setColumnFormula"Sets the formula to use in the data cells in the column.
setColumnFormula(formula: Formula, overwriteExistingValues: boolean): void Parameters
- formula:
FormulaThe formula for the data cells of the column or null to remove the current column formula.
- overwriteExistingValues:
booleanTrue to overwrite the existing cells values and apply the formula to all data cells in the column. False to only apply the formula to the cells with no value set.