Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compatibility Excel 2002 and 2000 in automation
Hello,
I have made a windows application in C#, and i automate Excel to print some data. On my dev machine i have Office XP installed (Excel 2002) so i get the COM dll from it, version 10.0 object library. The application is running well on machines with Excel 2002, the xls file open and data is inserted in the cells. But with Excel 2000 the process fail when opening the workbook. The exception is : System.NullReferenceException : Object not set to an instance of an object at Excel.workbooks.Open(...) Object oMissing = System.Reflection.Missing.Value; //monXLS = appliXLS.Workbooks.Open(nomFichier, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing); monXLS = appliXLS.Workbooks.Open(nomFichier, 0, false, 5, "", "", true, Excel.XlPlatform.xlWindows, "", false, false, 0, false, 0, true); Is there a way to make it work for both version 2000 and 2002 ? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Backwards Compatibility with Excel 2002 | Excel Discussion (Misc queries) | |||
Excel 2002 compatibility with earlier versions | Excel Discussion (Misc queries) | |||
VBA Compatibility Between Excel 2000 and 2002 | Excel Programming | |||
VBA - Macro backward compatibility from excel 2002 to excel 2000 | Excel Programming | |||
compatibility between excel 2002 and 2003 | Excel Programming |