Thanks for the reply Chip. I was hoping that VSTO had made some sort of
evolutionary step forward and had a better way to do this now...
Also, when using the code:
<ClassInterface(ClassInterfaceType.AutoDual), ComVisible(True)> _
Public Class ExcelDivision
End Class
....doesn't this also expose the System.Object methods to Excel? I haven't
tried it, but I read that in a blog post by Gabhan Berry
(
http://blogs.msdn.com/gabhan_berry/a...D00_sharp.aspx).
I was trying his method instead, but am having trouble figuring out how he
gets Excel to see his Functions class as an automation add-in. I tried and I
do not see it show up in the list.
"Chip Pearson" wrote:
> Everything still has to go via COM, but see
> http://www.cpearson.com/Excel/Creati...nctionLib.aspx for examples of
> creating a function lib in VB.NET.
>
>
> --
> Cordially,
> Chip Pearson
> Microsoft Most Valuable Professional
> Excel Product Group
> Pearson Software Consulting, LLC
> www.cpearson.com
> (email on web site)
>
>
>
>
>
> "ma1achai" <(E-Mail Removed)> wrote in message
> news:85496DEA-7F5C-4BE5-A6BE-(E-Mail Removed)...
> > What is the best way to code UDF's for Excel using VSTO in VS 2008?
> >
> > Are we still using an automation add-in through COM, or have they
> > developed
> > a slicker way of exposing functions?
> >
> > I noticed that if I'm using Excel Services (through SharePoint) that they
> > have a simple attribute that defines a function as an Excel UDF, as
> > follows:
> > [UdfMethod(IsVolatile = true, ReturnsPersonalInformation = true)]
> >
> > Is there something like that if you are not using SharePoint?
>