1.依赖:Microsoft.Office.Interop.Excel
.fsx
// Reference the Excel interop assembly
#r "Microsoft.Office.Interop.Excel"
open Microsoft.Office.Interop
// Run Excel as a visible application
let app = new ApplicationClass(Visible = true)
// Open a exiting file
let xlWorkBook = xlApp.Workbooks.Open(@"C:\Users\Ray\Desktop\0db-1m\test.xlsx")
et worksheet= xlWorkBook.Worksheets.["Sheet1"] :?>Excel.Worksheet