# Allowing the User to Enter Formulas

Learn how to enable user input of formulas in Spread for WinForms with our comprehensive guide.

## Content

Spread for WinForms supports the ability to type in a formula by simply starting with an equal’s sign (=). This is the default behavior in the worksheet where the displayed result depends on the cell type.
For example, an integer cell type displays the result as an integer, even if the result of the formula is not an integer. In this case, a number may appear rounded.
![](https://cdn.mescius.io/document-site-files/images/2238e618-a1fb-45a6-9ce5-9a4157bd2931/images/formulainput_equal.gif)
You can control whether to allow the users to enter formulas in a worksheet by setting the boolean value in [FpSpread.AllowUserFormulas](/spreadnet/api/latest/online-win/FarPoint.Win.Spread/FarPoint.Win.Spread.FpSpread.AllowUserFormulas.html) property.

```csharp
fpSpread1.AllowUserFormulas = true;
```

```vbnet
fpSpread1.AllowUserFormulas = True
```

To define specific formatting for currency and date cells or setting various cell types, refer to [Working with Editable Cell Types](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-setcelltypes/spwin-seteditcelltypes).
For information on the floating formula bar, where users can type in formulas and select cells dynamically, refer to [Working with the Formula Text Box](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulabar).

## Using Plus or Minus Sign

You can also input a formula in a worksheet by starting with a plus sign (+) or a minus sign (-). These signs function the same as the equal sign (=) and Excel users who are accustomed to using the plus or minus sign don't have to change their behavior when using Spread.
The equal sign is still automatically added before, so that formulas are converted to work as expected. For example, if you enter "+SUM(1,2)" when editing, it will be "=+SUM(1,2)" when displayed again.
![](https://cdn.mescius.io/document-site-files/images/2238e618-a1fb-45a6-9ce5-9a4157bd2931/images/formulainput_plus.gif)
When using the plus or minus sign to enter a formula, the users should be aware of the following behavior:

* If the text cannot be parsed as a formula, it'll be parsed as a simple value.
* If the text can be parsed as a formula, then:
    * If there are only numeric values ("+1"), percentage values ("+10%"), or percentage for scientific formula ("+1e-20%") then it will be parsed as a simple value along with its corresponding format.
    * Otherwise, the formula is set to the cell input.

> !type=note
> **Note:** This behavior only works with default cell type in flat style mode.

## Using the Properties Window

1. At design time, in the **Properties** window (in the **Behavior** category), select the **AllowUserFormulas** property.
2. Select **True** from the drop-down list to allow users to enter formulas or select **False** to prohibit them.

## Using the Spread Designer

1. Select the Spread component (or select Spread from the pull-down menu).
2. In the property list for the component (in the **Behavior** category), select the **AllowUserFormulas** property and select the value **True**.

From the **File** menu choose **Apply and Exit** to apply your changes to the component and exit Spread Designer.

## See Also

[Formulas in Cells](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula)
[Placing a Formula in Cells](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulaplace)
[Specifying a Cell Reference in a Formula](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulacellref)
[Specifying a Sheet Reference in a Formula](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulasheetref)
[Specifying an External Reference in a Formula](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-externalref)
[Using a Circular Reference in a Formula](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulacircref)
[Nesting Functions in a Formula](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulanested)
[Recalculating and Updating Formulas Automatically](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formularecalc)
[Finding a Value Using GoalSeek](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formula-goalseek)
[Creating and Using a Custom Name](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulacustomname)
[Creating and Using a Custom Function](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulacustomfunc)
[Creating and Using External Variable](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-external-variable)
[Using the Array Formula](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-arrayformula)
[Working with the Formula Text Box](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-formulabar)
[Setting up the Name Box](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-namebox)
[Using Language Package](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/UsingLanguagePackage)
[Accessing Data from Header or Footer](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-headerfooterformula)
[Managing External Reference](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/spwin-extrenalreference)
[Working With Dynamic Array Formulas](/spreadnet/docs/latest/online-win/overview/spwin-devguide/spwin-cell-formula/WorkingWithDynamicArrayFormulas)