Xlsm files using Microsoft.ACE.OLEDB.12.0

Connection string

This Microsoft ACE OLEDB 12.0 connection string can be used for connections to Excel 2007, Excel 2010 and Excel 2013.

Connect to Excel 2007 (and later) files with the Xlsm file extension. That is the Office Open XML format with macros enabled.

Provider=Microsoft.ACE.OLEDB.12.0;Data Source=c:\myFolder\myExcel2007file.xlsm;
Extended Properties
="Excel 12.0 Macro;
HDR=YES";

"HDR=Yes;" indicates that the first row contains columnnames, not data. "HDR=No;" indicates the opposite.