Aug 28, 2012 at 7:07 AM
Edited Aug 28, 2012 at 7:15 AM
I got all the files generated, and inserted the what I thought was the correct contents into app.config. But then when I run the project, I get this error:
Could not load type 'AppInstanceConfig.AppInstances' from assembly 'MultipleAppInstances'.
My app.config looks like this:
<section name="appInstances" type="AppInstanceConfig.AppInstances, MultipleAppInstances"/>
<appInstanceConfiguration id="1" left="20"/>
And the code, which fails, is:
Public Sub New()
' THIS LINE RAISES THE ERROR
Dim section = CType(ConfigurationManager.GetSection("appInstances"), AppInstances)
Dim config = (From el In section.Config.OfType(Of AppInstanceConfiguration)() Where el.Id = AppId).FirstOrDefault()
The configuration project "ConfigProject" is a part of a solution "MultipleAppInstances" with yet another project "MultipleAppInstances".
What is wrong?