Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Using UDF in COM Addin as formula in worksheet
I have written a COM addin in VB to store user defined data in
CustomDocumentProperties of a workbook. Now i want to insert these props in a cell like Application.ActiveCell.FormulaR1C1 = "=GETPROPERTY(""" & sPropertyName & """)" It works if i define the GETPROPERTY function directly in a module of workbook, but i want to define this function in the COM addin without writting a wrapper XLA. (see MSDN KnowledgeBase article Q256624 - Howto: Use a COM Add-In Function as an Excel Worksheet function) Is this possible??? Thanks in advance.Ralf |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Using UDF in COM Addin as formula in worksheet
Can you make your function a DLL/xll rather than a COM Addin.
http://msdn.microsoft.com/library/en...icedev_topic16 I think you can call that directly, but the article starts out: Microsoft Excel 2000 cannot call a function directly in a COM Add-in from a worksheet cell formula. However, you can create a Visual Basic for Applications (VBA) wrapper for the COM Add-in function so that the function may be called indirectly. If you are using xl2002, then you can use an Automation-Addin Create a Visual Basic Automation Add-in for Excel 2002 Worksheet Functions (Q285337) -- Regards, Tom Ogilvy "Ralf Zimmermann" wrote in message ... I have written a COM addin in VB to store user defined data in CustomDocumentProperties of a workbook. Now i want to insert these props in a cell like Application.ActiveCell.FormulaR1C1 = "=GETPROPERTY(""" & sPropertyName & """)" It works if i define the GETPROPERTY function directly in a module of workbook, but i want to define this function in the COM addin without writting a wrapper XLA. (see MSDN KnowledgeBase article Q256624 - Howto: Use a COM Add-In Function as an Excel Worksheet function) Is this possible??? Thanks in advance.Ralf |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Urgent Pls, how to convert an addin xlam file to xls worksheet in | Excel Discussion (Misc queries) | |||
Formula Evaluator Addin??? | Excel Discussion (Misc queries) | |||
How do I edit a worksheet that has been defined as an addin | Excel Discussion (Misc queries) | |||
AddIn | Excel Programming | |||
raw speed for excel worksheet functions? - xll -or com addin? | Excel Programming |