[RESOLVED] Error in reading excel 07 from vb.net 2005
Hi all,
i have the following error.
Code:
'Sheet1$' is not a valid name. Make sure that it does not include invalid characters or punctuation and that it is not too long.
At first, I can read the same excel file with the same sheet name without this error.
but now i change the development PC and it hit this error.
I'm using Excel 2007 with VB.Net 2005.
Here is my connection string:
Code:
"Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" & strFile & ";Extended Properties=""Excel 12.0 Xml;HDR=YES"";"
And I also added the COM references for Microsoft Excel Object 12.0 in my project.
Any idea??
Help :(
Thanks.
scsfdev
Re: Error in reading excel 07 from vb.net 2005
Sorry my bad.
I pointed to the wrong excel file that's why it can't find the sheet name.
sorry to bother u guys.