V
vinay
i am trying to read excel using this code. also tried with ApplicationClass.
Microsoft.Office.Interop.Excel.Application app = new
Microsoft.Office.Interop.Excel.Application();
Workbook book = null;
Worksheet sheet = null;
Range range = null;
book = app.Workbooks.Open(openFile.FileName, Missing.Value, Missing.Value,
Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value, Missing.Value);
sheet = (Worksheet)book.Worksheets[1];
i am getting error at app.workbooks.Open ----- Exception from HRESULT:
0x800A03EC
unable to find the solution
Thanks for any help.
Microsoft.Office.Interop.Excel.Application app = new
Microsoft.Office.Interop.Excel.Application();
Workbook book = null;
Worksheet sheet = null;
Range range = null;
book = app.Workbooks.Open(openFile.FileName, Missing.Value, Missing.Value,
Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value, Missing.Value);
sheet = (Worksheet)book.Worksheets[1];
i am getting error at app.workbooks.Open ----- Exception from HRESULT:
0x800A03EC
unable to find the solution
Thanks for any help.