Whoops, I'm amazed that I missed that
Dominick ODierno
Posts
-
problem with ref and out parameters -
problem with ref and out parametersI am attempting to write a function with the following declaration: void OpenExcel(string filename, out Excel.ApplicationClass XLApp, out Excel.Workbook XLWorkBook, out Excel.Sheets XLSheets, out Excel.Worksheet XLWorkSheet) where the function will open an instance of excel and the workbook with the given filename, and assign the application instance, the workbook, the worksheets collection and the default worksheet to the variables passed in respectively When I attempt to compile I receive the following errors: Argument '2': cannot convert from 'Microsoft.Office.Interop.Excel.Application' to 'out Microsoft.Office.Interop.Excel.ApplicationClass' Argument '3': cannot convert from 'Microsoft.Office.Interop.Excel.Workbook' to 'out Microsoft.Office.Interop.Excel.Workbook' Argument '4': cannot convert from 'Microsoft.Office.Interop.Excel.Sheets' to 'out Microsoft.Office.Interop.Excel.Worksheets' Argument '5': cannot convert from 'Microsoft.Office.Interop.Excel.Worksheet' to 'out Microsoft.Office.Interop.Excel.Worksheet' This also fails when I replace "out" with "ref" Anyone know how to fix this?
-
Serial Port 2.0 to 1.1 backward compatibilityok, good to know, thank you.
-
Serial Port 2.0 to 1.1 backward compatibilitySo if I developed it on a machine using .NET 2.0, compiled it, and moved the EXE to a computer with .NET 1.1, it would fail?
-
Serial Port 2.0 to 1.1 backward compatibilityIf I write a program, say in C#, to read and write to a serial port and use the SerialPort class in .NET 2.0, will this program be compatible with machines still using .NET framework 1.1?