officefileapi-devexpress-dot-spreadsheet-dot-cellrange-589e0ec6.md
Determines whether all cells in the range contain a formula.
Namespace : DevExpress.Spreadsheet
Assembly : DevExpress.Spreadsheet.v25.2.Core.dll
NuGet Package : DevExpress.Spreadsheet.Core
bool HasFormula { get; }
ReadOnly Property HasFormula As Boolean
| Type | Description |
|---|---|
| Boolean |
true , if all cells in the range contain a formula; otherwise, false.
|
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the HasFormula property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-spreadsheet-how-to-edit-rich-text/CS/SpreadsheetRichText/Form1.cs#L46
Cell activeCell = spreadsheetControl.ActiveCell;
if (activeCell.Value.IsEmpty || (!activeCell.HasFormula && activeCell.Value.IsText))
{
winforms-spreadsheet-how-to-edit-rich-text/VB/SpreadsheetRichText/Form1.vb#L40
Dim activeCell As Cell = spreadsheetControl.ActiveCell
If activeCell.Value.IsEmpty OrElse (Not activeCell.HasFormula AndAlso activeCell.Value.IsText) Then
Dim setRichTextItem As New SpreadsheetMenuItem("Set Rich Text", New EventHandler(AddressOf SetRichTextItemClick))
See Also