Skip to end of metadata
Go to start of metadata

In VBA, you can use Application.Caller.Rows.Count to find out the expected size of an array forula, so you can return an array of the right size.

In c# you can also do this!

Check out the page Writing an Excel COM Addin first so you can get hold of the Application object.

Then:

Labels: