tags:

views:

70

answers:

1

I am planning to develop a function in C# which will return a two dimensional array. This new C# function will be called through VB script. Also the length of the returned array will be dynamically changed so I am not sure how to return this array to vbscript.

Any insight on approach/pseudo code will be of great help. Thanks.

A: 

I would recommend looking at a specialised solution for C# and VBA like ManagedXLL, ExcelDNA etc if you are going to be doing more of this in the future.

This will help you easily create an in-process XLL that can be called from Excel / VBA directly.

Otherwise you could also call a web service instead as the 2003 Web Services Toolkit is very easy to set up too.

FinancialRadDeveloper