Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello,
I am trying to get data from an Excel file using OleDbConnection in C#.NET I have a function that returns a DataSet filled with data from the .xls file. Problem is, it works only if I have opened that file in Excel manualy before I run my function. If the file isn't opened, when trying "oleDbDataAdapter.Fill ( dataSet )" I'm receiving OleDbException: "External table is not in the expected format." I have tried to open the file using Excel 11.0 reference before running that function, but it didn't change anything. Seems like it's working only if the file is opened not in Read-Only mode, but the program is supposed to be working on several machines, possibly at the same time - cannot avoid situation, that the file is used by someone else. I know it is a common problem, and I also know there is no answer for that question so far. Does anyone managed to resolve such issue? Is there any other way to get data from .xls file without opening the Excel itself? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
assign dataset to matching dataset | Excel Programming | |||
Converting A Quarterly Dataset to Weekly Dataset | Excel Programming | |||
filling information from one cell and filling another. | Excel Worksheet Functions | |||
creating a new dataset | Excel Programming | |||
two dataset comparison | Excel Programming |