Goto the properties of the Excel Connection manager and change the ConnectionString property:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\Excelname.xls;Extended Properties="EXCEL 8.0;HDR=YES;IMEX=1";
"HDR=Yes;" indicates that the first row contains columnnames, not data
"IMEX=1;" tells the driver to always read "intermixed" data columns as text
IMEX = 0 is Export mode
IMEX = 1 is Import mode
IMEX = 2 is Linked mode
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\Excelname.xls;Extended Properties="EXCEL 8.0;HDR=YES;IMEX=1";
"HDR=Yes;" indicates that the first row contains columnnames, not data
"IMEX=1;" tells the driver to always read "intermixed" data columns as text
IMEX = 0 is Export mode
IMEX = 1 is Import mode
IMEX = 2 is Linked mode
No comments:
Post a Comment