# Array Formulas

This topic explains how to use array formulas in worksheets in the Spread for WPF.

## Content

Spread for WPF allows you to use array formulas in the worksheets. An array formula performs calculations on one or more items in an array and can return either a single result or multiple results. To create an array formula in a worksheet, you can use the [FormulaArray](/spreadnet/api/latest/online-wpf/GrapeCity.Spreadsheet/GrapeCity.Spreadsheet.IRange.FormulaArray.html) property of the **IRange** interface.
The following image demonstrates how to create an array formula in the worksheet.
![](https://cdn.mescius.io/document-site-files/images/0f63724f-fddf-4351-8c24-0b4338c0fda9/images/array-formula.png)
Refer to the following example code to create an array formula in the worksheet.
**C#**

```csharp
// Create array formula.
spreadSheet1.Workbook.ActiveSheet.Range("D1:D4").FormulaArray = "B1:B4*C1:C4";
```

**VB**

```auto
' Create array formula.
spreadSheet1.Workbook.ActiveSheet.Range("D1:D4").FormulaArray = "B1:B4*C1:C4"
```