## PivotTable::AddCalculatedField(const U16String\&, const U16String\&, bool) method


Adds a calculated field to pivot field.

```cpp
void Aspose::Cells::Pivot::PivotTable::AddCalculatedField(const U16String &name, const U16String &formula, bool dragToDataArea)
```


| Parameter | Type | Description |
| --- | --- | --- |
| name | const U16String\& | The name of the calculated field |
| formula | const U16String\& | The formula of the calculated field. |
| dragToDataArea | bool | True,drag this field to data area immediately |

## See Also

* Class [Vector](../../../aspose.cells/vector/)
* Class [U16String](../../../aspose.cells/u16string/)
* Class [PivotTable](../)
* Namespace [Aspose::Cells::Pivot](../../)
* Library [Aspose.Cells for C++](../../../)
## PivotTable::AddCalculatedField(const char16_t*, const char16_t*, bool) method


Adds a calculated field to pivot field.

```cpp
void Aspose::Cells::Pivot::PivotTable::AddCalculatedField(const char16_t *name, const char16_t *formula, bool dragToDataArea)
```


| Parameter | Type | Description |
| --- | --- | --- |
| name | const char16_t* | The name of the calculated field |
| formula | const char16_t* | The formula of the calculated field. |
| dragToDataArea | bool | True,drag this field to data area immediately |

## See Also

* Class [Vector](../../../aspose.cells/vector/)
* Class [PivotTable](../)
* Namespace [Aspose::Cells::Pivot](../../)
* Library [Aspose.Cells for C++](../../../)
## PivotTable::AddCalculatedField(const U16String\&, const U16String\&) method


Adds a calculated field to pivot field and drag it to data area.

```cpp
void Aspose::Cells::Pivot::PivotTable::AddCalculatedField(const U16String &name, const U16String &formula)
```


| Parameter | Type | Description |
| --- | --- | --- |
| name | const U16String\& | The name of the calculated field |
| formula | const U16String\& | The formula of the calculated field. |

## See Also

* Class [Vector](../../../aspose.cells/vector/)
* Class [U16String](../../../aspose.cells/u16string/)
* Class [PivotTable](../)
* Namespace [Aspose::Cells::Pivot](../../)
* Library [Aspose.Cells for C++](../../../)
## PivotTable::AddCalculatedField(const char16_t*, const char16_t*) method


Adds a calculated field to pivot field and drag it to data area.

```cpp
void Aspose::Cells::Pivot::PivotTable::AddCalculatedField(const char16_t *name, const char16_t *formula)
```


| Parameter | Type | Description |
| --- | --- | --- |
| name | const char16_t* | The name of the calculated field |
| formula | const char16_t* | The formula of the calculated field. |

## See Also

* Class [Vector](../../../aspose.cells/vector/)
* Class [PivotTable](../)
* Namespace [Aspose::Cells::Pivot](../../)
* Library [Aspose.Cells for C++](../../../)
