Intellisense

65 views
Skip to first unread message

Brian

unread,
Sep 7, 2023, 7:49:15 PM9/7/23
to Excel-DNA
Hi, 

When I follow the steps here:
https://excel-dna.net/docs/guides-basic/Intellisense

I get this error on startup:

Initialization [Error] DnaLibrary AutoOpen Error : TargetInvocationException - Exception has been thrown by the target of an invocation.

I am using the below code. If I uncomment the call to Install inside AutoOpen, then the addin loads and I can use AddThem function (without intellisense of course)

Using latest Office 365 and below packages. Any ideas how to debug?


        <PackageReference Include="ExcelDna.Addin" Version="1.6.0" />
        <PackageReference Include="ExcelDna.Registration" Version="1.6.0" />
        <PackageReference Include="ExcelDna.Intellisense" Version="1.6.0" />


using ExcelDna.Integration;
using ExcelDna.IntelliSense;

public class IntelliSenseAddIn : IExcelAddIn
{
    public void AutoOpen()
    {
        IntelliSenseServer.Install();
    }
    public void AutoClose()
    {
        IntelliSenseServer.Uninstall();
    }

    [ExcelFunction(Description = "A useful test function that adds two numbers, and returns the sum.")]
    public static double AddThem(
    [ExcelArgument(Name = "Augend", Description = "is the first number, to which will be added")]
    double v1,
    [ExcelArgument(Name = "Addend", Description = "is the second number that will be added")]
    double v2)
    {
        return v1 + v2;
    }
}


Thanks
Brian

Govert van Drimmelen

unread,
Sep 8, 2023, 2:36:48 AM9/8/23
to exce...@googlegroups.com

Hi Brian,

 

Can you check with the current prerelease version 1.7.0-rc6 of the Excel-DNA packages?

 

-Govert

--
You received this message because you are subscribed to the Google Groups "Excel-DNA" group.
To unsubscribe from this group and stop receiving emails from it, send an email to exceldna+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/bae185dc-fe8d-4803-9120-9ac343a1d7b7n%40googlegroups.com.

Brian

unread,
Sep 8, 2023, 10:17:50 AM9/8/23
to Excel-DNA
Hi Govert

It is working with 1.7.0-rc6. Interesting! Is this version stable enough for production use?

Brian

Reply all
Reply to author
Forward
0 new messages