Upgrading to .NET 4.0 from .NET 3.5: Are there configuration file breaking changes? -
our executable compiled against .net 3.5. don't own source code , can't recompile it. so, run .net 4.0, added config file, per this page:
<startup> <supportedruntime version="v4.0" sku=".netframework,version=v4.0" /> </startup>
now, different error seems related configuration file:
i suspected there .net 4.0 doesn't our complex configuration file. verify this, did following:
created blank .net 3.5 winforms exe added config supportedruntime shown above verified ran .net 4.0 dlls using process explorer.i began simplify complex configuration file narrow downwards issue, , got downwards far far. know problem be?
<?xml version="1.0" encoding="utf-8"?> <configuration> <startup> <supportedruntime version="v4.0" /> </startup> <configsections> <sectiongroup name="spring"> <section name="context" type="spring.context.support.contexthandler, spring.core" /> <section name="objects" type="spring.context.support.defaultsectionhandler, spring.core" /> </sectiongroup> </configsections> <spring> <context type="spring.context.support.xmlapplicationcontext, spring.core" name="default"> <resource uri="config://spring/objects" /> </context> <objects xmlns="http://www.springframework.net" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xsi:schemalocation="http://www.springframework.net http://www.springframework.net/xsd/spring-objects.xsd" default-lazy-init="true"> <object id="foo1" type="foo.bar1, foo.bar"> <description>lorem ipsum</description> </object> <object id="foo2" singleton="false" type="foo.bar2, foo.bar"> <description>lorem ipsum</description> </object> <object id="foo3" singleton="false" type="foo.bar3, foo.bar"> <description>lorem ipsum</description> </object> <object id="foo4" type="foo.bar4, foo.bar"> <description>lorem ipsum</description> </object> <object id="foo5" type="foo.bar5, foo.bar"> <description> lorem ipsum </description> <constructor-arg> <list element-type="foo.ibar5, foo.bar"> <ref object="foo4" /> </list> </constructor-arg> </object> </objects> </spring> </configuration>
turns out problem configsections has first kid of configuration.
i figured out putting complex configuration blank winforms config file, reading configuration , looking @ details of exception thrown.
.net .net-4.0
No comments:
Post a Comment