I am trying to use JavaScript API for Excel.
Does anyone know how to trigger calculation for a cell, a range, a worksheet or a workbook?
For instance, the following code selects a range, but how can we re-calculate the range?
Excel.run(function (ctx) {
var sheetName = "Sheet1";
var rangeAddress = "F5:F10";
var range = ctx.workbook.worksheets.getItem(sheetName).getRange(rangeAddress);
range.select();
return ctx.sync();
});
}).catch(function(error) {
console.log("Error: " + error);
if (error instanceof OfficeExtension.Error) {
console.log("Debug info: " + JSON.stringify(error.debugInfo));
}
});