
3,942 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
When I put the formula "VLOOKUP(A1;F1:G1;2;FALSE)" in an Excel Script (see below) I have got the error "
Line 4: Range setFormulaLocal: The argument is invalid, missing, or incorrectly formatted.
My Excel Script is:
function main(workbook: ExcelScript.Workbook) {
let selectedSheet = workbook.getActiveWorksheet();
// Set range B1 on selectedSheet
selectedSheet.getRange("B1").setFormulaLocal("=VLOOKUP(A1,$F$1:$G$1,2,FALSE)");
}
Did you try setFormula instead of setFormulaLocal?