Using a DLL that has data access capabilities causes an error
<p>I'm at the stage of linking my logic (a DLL) to my UI (winform). My DLL uses EF 4.1.</p>

<p>Here's the line in the myEFContext.Designer.cs that throws the exception:</p>

<pre><code>public DispatchContext() : base("name=DispatchContext", "DispatchContext") //&lt;--- This line
{
    this.ContextOptions.LazyLoadingEnabled = true;
    OnContextCreated();
}
</code></pre>

<p>The exception thrown is (free translation)</p>

<pre><code>ArgumentException
The specified connexion name is not found in the configuration [...]
</code></pre>

<p>If I do the exact same thing from a winform project inside the same solution as my DLL, all works fine.</p>

<ol>
<li>How is it that the UI has to have knowledge of the data source?</li>
<li>How can this be fixed?</li>
</ol>
