Interface IOdfFormulaEvaluator
Represents an evaluator that can calculate formula results. 代表能夠計算公式結果的評估器。
public interface IOdfFormulaEvaluator
Methods
Evaluate(string, IEvaluationContext)
Evaluates a formula string within a spreadsheet content model. 在試算表的內容模型中評估公式字串。
object Evaluate(string formula, IEvaluationContext context)
Parameters
formulastringThe normalized Excel-style formula string to evaluate, such as "SUM(A1:B10)". / 要評估的標準化 Excel 樣式公式字串,例如 "SUM(A1:B10)"。
contextIEvaluationContextThe evaluation context that provides cell and range data access. / 提供儲存格與範圍資料存取的評估內容模型。
Returns
- object
The evaluated result, whose type may be double, string, bool, or OdfFormulaError. / 評估後的結果,其型別可能為 double、string、bool 或 OdfFormulaError。