I'm in the process of figuring out how to migrate an old VBA based Excel Add-in to VSTO .net
Quite unfortunately, UDF function support in Excel is critical for the add-in I'm updating and yet it is not supported in the present version of VSTO nor will it ever be with Excel 2003.
Thus, I'm stuck figuring out a means around the issue.
After a great deal of digging, I found a means to create VBA code from within .net and add it when the runtime loads. A great summary of how to do this is available here: http://blogs.msdn.com/pstubbs/archive/2004/12/31/344964.aspx
The issue, however, is just as Paul outlines being that you then have to deal with 2 different security models, both .net and VBA Macros.
I believe after much frustration I have overcome the hurdle of deploying my VSTO code with the correct security of being able to install and run the add-in. What I am now left with, is how to overcome the security constraints related to dynamically loading VBA macros from within a VSTO addin.
Any tips, thoughts, suggestions would be greatly appreciated on good resources or solutions for configuring macro security from within VSTO.
Thanks