[]
Gets or sets the formula of the cells represented by this IRange in A1-style notation.
string Formula { get; set; }
Property Formula As String
| Type | Description |
|---|---|
| string | The formula. |
worksheet.Range["A1"].Value = 10;
worksheet.Range["A2"].Value = 5;
IRange range = worksheet.Range["B1"];
range.Formula = "=A1+A2";
workbook.Calculate();
object value = range.Value;