Note that there are some explanatory texts on larger screens.

plurals
  1. POVS2010 debug/release.config not working
    primarykey
    data
    text
    <p>I'm having a bit of trouble with my <code>web.debug.config</code> and <code>web.release.config</code> files.</p> <p>To be more specific, my webpage will only use the default <code>web.config</code> file, and completely ignore the <code>debug</code> and <code>release</code> files. This happens not only when I run the project locally, but also when I publish it to an IIS server.</p> <p>I am using Visual Studio 2010 Ultimate (no Service Pack).</p> <p>Here are the config files:</p> <p><strong><code>web.config</code>:</strong></p> <pre class="lang-xml prettyprint-override"><code>&lt;?xml version="1.0"?&gt; &lt;configuration&gt; &lt;connectionStrings&gt; &lt;add name="MyConn" connectionString="SomeConnectionString" providerName="System.Data.SqlClient"/&gt; &lt;/connectionStrings&gt; &lt;/configuration&gt; </code></pre> <p><strong><code>web.debug.config</code> and <code>web.release.config</code>:</strong></p> <pre class="lang-xml prettyprint-override"><code>&lt;?xml version="1.0"?&gt; &lt;configuration xmlns:xtd="http://schemas.microsoft.com/XML-Document-Transform"&gt; &lt;connectionStrings&gt; &lt;add name="MyConn" connectionString="SomeOtherConnectionString" providerName="System.Data.SqlClient" xtd:Transform="Replace" xtd:Locator="Match(name)"/&gt; &lt;/connectionStrings&gt; &lt;/configuration&gt; </code></pre> <p>As I mentioned before, the website uses the connection string from the <code>web.config</code> file, and not from the <code>web.release.config</code>.</p> <p>Another interesting point is that in the physical folder to which I published the project, all three <code>config</code> files exist; each exactly the same as they appear in the VS solution.</p> <p>Suggestions, anyone?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload