fpspreadsheet: Add method TsWorksheet.GetFormula to return the formula associated with a cell.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@6818 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz 2019-02-24 11:25:28 +00:00
parent 6858d3da86
commit 748fea48a1

View File

@ -383,6 +383,7 @@ type
procedure CalcSheet;
function ConvertFormulaDialect(ACell: PCell; ADialect: TsFormulaDialect): String;
function ConvertRPNFormulaToStringFormula(const AFormula: TsRPNFormula): String;
function GetFormula(ACell: PCell): PsFormula;
{ Data manipulation methods - For Cells }
procedure CopyCell(AFromCell, AToCell: PCell); overload;
@ -3055,6 +3056,15 @@ begin
end;
end;
{@@ ----------------------------------------------------------------------------
Returns a pointer to the formula record assigned to a cell, or nil if the
cell has no formula
-------------------------------------------------------------------------------}
function TsWorksheet.GetFormula(ACell: PCell): PsFormula;
begin
Result := FFormulas.FindFormula(ACell);
end;
{@@ ----------------------------------------------------------------------------
Returns the index of the effective cell format to be used at the specified
cell.