I'm running into a problem trying to read data from an Excel worksheet.
The one I created works fine.The one I received from another user, I had to
change the 1st sheet's name to "Manual_tankInventory" to match the name of
the of the sheet to be called (workbook name is ok).
No matter what I did, I always recieved the error message below.
Is there anything with Excel that causes the problem?
Thanks
Bill
---------------------------
DISPATCH_2005
---------------------------
System.Data.OleDb.OleDbException: The Microsoft Jet database engine could
not find the object 'Manual_tankInventory'. Make sure the object exists and
that you spell its name and the path name correctly.
at
System.Data.OleDb.OleDbCommand.ExecuteCommandTextF orSingleResult(tagDBPARAMS
dbParams, Object& executeResult)
at System.Data.OleDb.OleDbCommand.ExecuteCommandText( Object&
executeResult)
at System.Data.OleDb.OleDbCommand.ExecuteCommand(Comm andBehavior
behavior, Object& executeResult)
at System.Data.OleDb.OleDbCommand.ExecuteReaderIntern al(CommandBehavior
behavior, String method)
at System.Data.OleDb.OleDbCommand.ExecuteReader(Comma ndBehavior behavior)
at
System.Data.OleDb.OleDbCommand.System.Data.IDbComm and.ExecuteReader(CommandBehavior
behavior)
at System.Data.Common.DbDataAdapter.FillInternal(Data Set dataset,
DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String
srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String
srcTable)
at DISPATCH_2005.frmLVC_tankInventory.ManualTank_Exce lImport(String
xlsPath, String xlsSheet) in
C:\VS2005\DISPATCH_2005\frmLVC_tankInventory.vb:li ne 414
---------------------------
OK
---------------------------