# FormatColumn

Canonical page: https://www.adaptabletools.com/docs/reference/formatcolumn

Colours a cell, changes how its value is displayed, or both.

`Scope` is required. `Style` and `DisplayFormat` can be set together. Omit `Rule` to apply the format on every row in scope. `Target` defaults to `'cell'` (`'columnHeader'` formats the header). Suspend with `IsSuspended`.

```ts title="TypeScript"
export interface FormatColumn extends SuspendableObject 
```

###### Extends

[`SuspendableObject`](https://www.adaptabletools.com/docs/reference/suspendableobject.md)

## Properties

| Property | Type | Description | Default |
| --- | --- | --- | --- |
| [ColumnGroupScope](https://www.adaptabletools.com/docs/reference/formatcolumn.md#columngroupscope) | [`ColumnGroupScope`](https://www.adaptabletools.com/docs/reference/columngroupscope.md) | When a format applies to a column inside a column group.<br/><br/>Omit it to apply the format whether the parent group is expanded or collapsed. `'Expanded'` applies only while the parent group is expanded. `'Collapsed'` applies only while it is collapsed. `'Both'` applies in either state. A column that is the only leaf of a top-level group ignores an explicit scope. |   |
| [DisplayFormat](https://www.adaptabletools.com/docs/reference/formatcolumn.md#displayformat) | [`DisplayFormat`](https://www.adaptabletools.com/docs/reference/displayformat.md) | Display Format to apply to Column. Can be a concrete `AdaptableFormat`<br/>(Numeric, String or Date) **or** the name of a numeric preset such as<br/>`'Percentage'`, `'Thousand'`, `'Million'`, `'Dollar'`, `'Sterling'`,<br/>which is resolved at render time. |   |
| [Name](https://www.adaptabletools.com/docs/reference/formatcolumn.md#name) | `string` | Name of the Format Column definition |   |
| [RowScope](https://www.adaptabletools.com/docs/reference/formatcolumn.md#rowscope) | [`RowScope`](https://www.adaptabletools.com/docs/reference/rowscope.md) | Row kinds to skip. Each flag excludes that kind. When omitted, data, group, summary and total rows are all included. |   |
| [Rule](https://www.adaptabletools.com/docs/reference/formatcolumn.md#rule) | `string` | AdapTableQL boolean expression (evaluated per row) deciding whether to apply the Format, e.g. `[price] > 100`; if undefined the Format is always applied |   |
| [Scope](https://www.adaptabletools.com/docs/reference/formatcolumn.md#scope) | [`ColumnScope`](https://www.adaptabletools.com/docs/reference/columnscope.md) | Where Format will be applied: whole Row, some Columns, or Columns of DataType |   |
| [Style](https://www.adaptabletools.com/docs/reference/formatcolumn.md#style) | [`AdaptableStyle`](https://www.adaptabletools.com/docs/reference/adaptablestyle.md) | Colours, font and CSS class applied to the cell or header. Can be set together with `DisplayFormat`. |   |
| [Target](https://www.adaptabletools.com/docs/reference/formatcolumn.md#target) | [`FormatColumnTarget`](https://www.adaptabletools.com/docs/reference/formatcolumntarget.md) | Where in Column to apply Format (`cell` or `columnHeader`) | &#39;cell&#39; |
| [IsReadOnly](https://www.adaptabletools.com/docs/reference/formatcolumn.md#isreadonly) | `boolean` | Sets Entity to ReadOnly (overwriting a Strategy Entitlement of &#39;Full&#39;) |   |
| [IsSuspended](https://www.adaptabletools.com/docs/reference/formatcolumn.md#issuspended) | `boolean` | Suspends (i.e. turns off) an Adaptable Object |   |

## Property Details

### ColumnGroupScope

When a format applies to a column inside a column group.

Omit it to apply the format whether the parent group is expanded or collapsed. `'Expanded'` applies only while the parent group is expanded. `'Collapsed'` applies only while it is collapsed. `'Both'` applies in either state. A column that is the only leaf of a top-level group ignores an explicit scope.

```ts title="TypeScript"
ColumnGroupScope?: ColumnGroupScope;
```

###### Property Value

[`ColumnGroupScope`](https://www.adaptabletools.com/docs/reference/columngroupscope.md)

### DisplayFormat

Display Format to apply to Column. Can be a concrete `AdaptableFormat`
(Numeric, String or Date) **or** the name of a numeric preset such as
`'Percentage'`, `'Thousand'`, `'Million'`, `'Dollar'`, `'Sterling'`,
which is resolved at render time.

```ts title="TypeScript"
DisplayFormat?: DisplayFormat;
```

###### Property Value

[`DisplayFormat`](https://www.adaptabletools.com/docs/reference/displayformat.md)

### Name

Name of the Format Column definition

```ts title="TypeScript"
Name: string;
```

###### Property Value

`string`

### RowScope

Row kinds to skip. Each flag excludes that kind. When omitted, data, group, summary and total rows are all included.

```ts title="TypeScript"
RowScope?: RowScope;
```

###### Property Value

[`RowScope`](https://www.adaptabletools.com/docs/reference/rowscope.md)

### Rule

AdapTableQL boolean expression (evaluated per row) deciding whether to apply the Format, e.g. `[price] > 100`; if undefined the Format is always applied

```ts title="TypeScript"
Rule?: string;
```

###### Property Value

`string`

### Scope

Where Format will be applied: whole Row, some Columns, or Columns of DataType

```ts title="TypeScript"
Scope: ColumnScope;
```

###### Property Value

[`ColumnScope`](https://www.adaptabletools.com/docs/reference/columnscope.md)

### Style

Colours, font and CSS class applied to the cell or header. Can be set together with `DisplayFormat`.

```ts title="TypeScript"
Style?: AdaptableStyle;
```

###### Property Value

[`AdaptableStyle`](https://www.adaptabletools.com/docs/reference/adaptablestyle.md)

### Target

Where in Column to apply Format (`cell` or `columnHeader`)

```ts title="TypeScript"
Target?: FormatColumnTarget;
```

###### Default Value

&#39;cell&#39;

###### Property Value

[`FormatColumnTarget`](https://www.adaptabletools.com/docs/reference/formatcolumntarget.md)

### IsSuspended

> *Inherited from [SuspendableObject](https://www.adaptabletools.com/docs/reference/suspendableobject.md)*

Suspends (i.e. turns off) an Adaptable Object

```ts title="TypeScript"
IsSuspended?: boolean;
```

###### Property Value

`boolean`

### IsReadOnly

> *Inherited from [AdaptableObject](https://www.adaptabletools.com/docs/reference/adaptableobject.md)*

Sets Entity to ReadOnly (overwriting a Strategy Entitlement of &#39;Full&#39;)

```ts title="TypeScript"
IsReadOnly?: boolean;
```

###### Property Value

`boolean`
