Hi
We currently have an Excel spreadsheet containing a large amount of VBA code. The VBA code is responsible for:
- Manipulating, transforming and formatting sheet data.
- Making calls to C# and C++ COM exposed functionality. In doing so marshalling the sheet data into the C#/C++ methods, getting the results and updating the sheet with the results.
As well as other utility code as required.
We now want to add a new sheet to our Excel workbook and we don't want any VBA. We want to use C#. As I see it I'm limited to the following options:
- Port the whole project to VSTO manually recoding the VBA as C# in the VSTO project.
- Write the new sheet's functionality in C# and expose it via COM. The C# code would make use of the Excel PIAs in order to update the sheet. The sheet would need a very thin layer of VBA to marshall data to the C# methods.
I don't think ManagedXLL will help me in this as my code requirements are as much about processing sheet data as they are about updating the sheet with results.
Please comment/ask for any more details.
Thanks.