How do you open an Excel workbook using JavaScript for Automation?
let excelApp = Application("Microsoft Excel");
let path = Path("/Users/me/Test.xlsx");
excelApp.openWorkbook(path);
gets error 50 "parameter error".
How do you open an Excel workbook using JavaScript for Automation?
let excelApp = Application("Microsoft Excel");
let path = Path("/Users/me/Test.xlsx");
excelApp.openWorkbook(path);
gets error 50 "parameter error".
I figured it out:
I also figured out how to get the contents of the data:
source: Yosemite JXA release notes and Script Editor dictionary entry for Microsoft Excel