SpreadJS Documentation
setArrayFormula Method
The start row index.
The start column index.
The number of rows in the range.
The number of columns in the range.
The array formula to place in the specified range.
Sets a formula in a specified cell in the specified sheet area.
Syntax
var instance = new GcSpread.Sheets.Sheet(name);
var returnValue; // Type: any
returnValue = instance.setArrayFormula(row, col, rowCount, colCount, value);
function setArrayFormula( 
   row : number,
   col : number,
   rowCount : number,
   colCount : number,
   value : string
) : any;

Parameters

row
The start row index.
col
The start column index.
rowCount
The number of rows in the range.
colCount
The number of columns in the range.
value
The array formula to place in the specified range.
Example
This example uses the setArrayFormula method.
activeSheet.getCell(1,1).value(3);
activeSheet.getCell(2,1).value(1);
activeSheet.getCell(3,1).value(3);
activeSheet.getCell(4,1).value(7);
activeSheet.getCell(1,2).value(7);
activeSheet.getCell(2,2).value(7);
activeSheet.getCell(3,2).value(7);
activeSheet.getCell(4,2).value(7);
spread.canUserEditFormula(true);
activeSheet.setArrayFormula(0, 3, 4, 1, "B2:B5*C2:C5");
See Also

Reference

Sheet type

 

 


Copyright © GrapeCity, inc. All rights reserved.

Send comments on this topic.