AddIn doesn't load when configuration file is present

312 views
Skip to first unread message

candy.c

unread,
Oct 2, 2015, 3:14:52 PM10/2/15
to Excel-DNA
Govert,

After I upgraded to the version 0.33.9 (latest as of today), I encountered a problem that when a config file is present, the AddIn wouldn't load at all.  Meaning if I put a break point on AutoOpen, it never reached there.

xll:          XXXXX-AddIn.xll
config:    XXXXX-AddIn.xll.config

Output from the debug window suggests the loading of the app domain (?) stopped prematurely.

#1) without .config

'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'ExcelDna.Loader'. Cannot find or open the PDB file.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System\v4.0_4.0.0.0__b77a5c561934e089\System.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'ExcelDna.Integration'. Cannot find or open the PDB file.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Configuration\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Configuration.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Core\v4.0_4.0.0.0__b77a5c561934e089\System.Core.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Xml\v4.0_4.0.0.0__b77a5c561934e089\System.Xml.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Windows.Forms\v4.0_4.0.0.0__b77a5c561934e089\System.Windows.Forms.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Drawing\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'XXXXX-Lib'. Symbols loaded.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'ExcelDna.DynamicDelegateAssembly'.


#2) with .config

'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'ExcelDna.Loader'. Cannot find or open the PDB file.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System\v4.0_4.0.0.0__b77a5c561934e089\System.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Configuration\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Configuration.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Core\v4.0_4.0.0.0__b77a5c561934e089\System.Core.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Xml\v4.0_4.0.0.0__b77a5c561934e089\System.Xml.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'EXCEL.EXE' (CLR v4.0.30319: FullTrustSandbox(Excel-DNA: XXXXX-AddIn.xll)): Loaded 'ExcelDna.Integration'. Cannot find or open the PDB file.


Thank you.

Govert van Drimmelen

unread,
Oct 3, 2015, 3:45:08 AM10/3/15
to <exceldna@googlegroups.com>
Hi,

It's not a problem that has been reported previously.

What is inside you .config file?
Does it happen even with a simple add-in and a simple .config file?

-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 post to this group, send email to exce...@googlegroups.com.
Visit this group at http://groups.google.com/group/exceldna.
For more options, visit https://groups.google.com/d/optout.

candy.c

unread,
Oct 5, 2015, 4:44:58 PM10/5/15
to Excel-DNA
Nothing non standard:

<?xml version="1.0" encoding="utf-8"?>

<configuration>

<configSections>

<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->

<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />

</configSections>

<connectionStrings>

</connectionStrings>

<startup>

<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />

</startup>

<entityFramework>

<defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">

<parameters>

<parameter value="mssqllocaldb" />

</parameters>

</defaultConnectionFactory>

<providers>

      <provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />

</providers>

</entityFramework>

<runtime>

<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">

<dependentAssembly>

<assemblyIdentity name="Autofac" publicKeyToken="17863af14b0044da" culture="neutral" />

<bindingRedirect oldVersion="0.0.0.0-3.5.0.0" newVersion="3.5.0.0" />

</dependentAssembly>

</assemblyBinding>

</runtime>

</configuration>


Is there anyway to turn on "logging" in the appdomain creation code?

Govert van Drimmelen

unread,
Oct 5, 2015, 6:52:43 PM10/5/15
to exce...@googlegroups.com
You can try to enable verbose logging. See https://github.com/Excel-DNA/ExcelDna/wiki/Diagnostic-Logging

Otherwise, you might test with a simple setup, to see what part of the configuration is causing the problem.

-Govert


From: exce...@googlegroups.com [exce...@googlegroups.com] on behalf of candy.c [candy....@gmail.com]
Sent: 05 October 2015 10:44 PM
To: Excel-DNA
Subject: Re: [ExcelDna] AddIn doesn't load when configuration file is present

candy.c

unread,
Oct 6, 2015, 9:12:23 AM10/6/15
to Excel-DNA
trial and error worked.  I found a section of configuration which was read by a library that's been uninstalled.   thank you.
To post to this group, send email to exc...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages