Opening Excel Document Via c# 
Author Message
 Opening Excel Document Via c#

I have a project where I have to open an existing office
XP Excel Doc with several worksheets, and parse it. But I
can't for the life of me figure out how to open the dang
thing using C#. I have looked all over msdn and the params
for the open method don't look even remotely the same as
what came in via my interop package.
Note: also posted on microsoft.public.excel.interopoledde

Here is what the method looks like:

Excel.Workbook _Open ( System.String Filename ,
System.Object UpdateLinks , System.Object ReadOnly ,
System.Object Format , System.Object Password ,
System.Object WriteResPassword , System.Object
IgnoreReadOnlyRecommended , System.Object Origin ,
System.Object Delimiter , System.Object Editable ,
System.Object Notify , System.Object Converter ,
System.Object AddToMru )

My code I was trying:
excelFileName = openFileDialog1.FileName;

Excel.Workbooks wb = ??????;

try
{
wb.Open(
excelFileName ,false ,true ,null,null,null,true,null,null,f
alse,false,false,false,true,false);

Quote:
}

catch (Exception debug1)
{
        string sdfsd = debug1.Message;
Quote:
}



Sat, 04 Jun 2005 06:29:51 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Cannot Open Excel Document Via Explorer

2. Opening Other Documents from Excel via macro

3. Open Document via Excel vba coding

4. Opening a word document via Excel

5. Opening Word/Excel documents from Visual Test via OLE

6. Open Document via Excel vba coding

7. Cannot Open Excel File via Outlook or via Windows Explorer

8. unable to open excel documents without opening excel program

9. Create email with embedded Excel document via Excel VBA

10. Open files via Explorer, explorer ontop of Excel after opening


 
Powered by phpBB® Forum Software © phpBB Group