SpreadJS Documentation
hasFormula Method
The row index.
The column index.
Gets whether there is a formula in the specified cell in this sheet.
Syntax
var instance = new GcSpread.Sheets.Sheet(name);
var value; // Type: boolean
value = instance.hasFormula(row, col);
function hasFormula( 
   row : number,
   col : number
) : boolean;

Parameters

row
The row index.
col
The column index.

Return Value

true if the cell contains a formula; otherwise, false.
Example
This example returns whether there is a formula in the specified cell.
activeSheet.setValue(0,0,1);
activeSheet.setValue(0,1,2);
activeSheet.setValue(0,2,10);
activeSheet.getCell(1,1).formula("=SUM(A1:C1)");
var formula = activeSheet.hasFormula(1,1,GcSpread.Sheets.SheetArea.viewport);
alert(formula);
See Also

Reference

Sheet type

 

 


Copyright © GrapeCity, inc. All rights reserved.

Send comments on this topic.