title: Where to place the Settings for External *.dll to run VS code Locally
body: <p>I am using an Azure Function I created with VS Code and added an external dependency (it's a Class Library created in VS 2022 *.dll). The External dependency requires me to have a connection string to an Azure SQL Server to work accordingly. I want it, to run locally to determine the outcome of the process, but I am unable to do it so.</p>
  <p>I have added the dependency in the *.csproj as:</p>
  <pre><code>&lt;ItemGroup&gt;
      &lt;Reference Include=&quot;HostServiceClassLib&quot;&gt;
        &lt;HintPath&gt;..\..\..\..\..\..\HostServiceClassLib.dll&lt;/HintPath&gt;
      &lt;/Reference&gt;
    &lt;/ItemGroup&gt;
  </code></pre>
  <h2><strong>What I did so far,</strong></h2>
  <p>In many places from VS Code, I added the settings namely <code>JksbMsSqlConnection</code>. Thus, so far included the following locations.</p>
  <ol>
  <li>Folder &gt; <code>local.Settings.json</code></li>
  </ol>
  <pre><code>{
    &quot;IsEncrypted&quot;: false,
    &quot;Values&quot;: {
      &quot;AzureWebJobsStorage&quot;: &quot;&quot;,
      &quot;FUNCTIONS_WORKER_RUNTIME&quot;: &quot;dotnet&quot;
    },
    &quot;ConnectionStrings&quot;: {
      &quot;JksbMsSqlConnection&quot;: &quot;xxxxxxxxxxxx&quot;
    }
  }
  </code></pre>
  <ol start="2">
  <li>Folder &gt; vscode &gt; <code>settings.json</code></li>
  </ol>
  <pre><code>    {
        &quot;azureFunctions.deploySubpath&quot;: &quot;bin/Release/net6.0/publish&quot;,
        &quot;azureFunctions.projectLanguage&quot;: &quot;C#&quot;,
        &quot;azureFunctions.projectRuntime&quot;: &quot;~4&quot;,
        &quot;debug.internalConsoleOptions&quot;: &quot;neverOpen&quot;,
        &quot;azureFunctions.preDeployTask&quot;: &quot;publish (functions)&quot;,
        &quot;JksbMsSqlConnection&quot;: &quot;xxxxxx&quot;
      }
  </code></pre>
  <ol start="3">
  <li>Folder &gt; Properties &gt; <code>launchSettings.json</code></li>
  </ol>
  <pre><code>    {
        &quot;profiles&quot;: {
          &quot;CDSFileComposerFunc&quot;: {
            &quot;commandName&quot;: &quot;Project&quot;,
            &quot;commandLineArgs&quot;: &quot;--port xxx&quot;,
            &quot;launchBrowser&quot;: false,
            &quot;environmentVariables&quot;: {
              &quot;JksbMsSqlConnection&quot;: &quot;xxxxxx&quot;
            }
          }
        }
      }
  </code></pre>
  <p>I even added the prefix as <code>SQLAZURECONNSTR_</code> but still no luck in all places above.</p>
  <p>However, if I deploy to Azure and have the Settings under Azure Function &gt; Configuration &gt; Connection String it works!</p>
  <p><a href="https://i.stack.imgur.com/uwir1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uwir1.png" alt="enter image description here" /></a></p>
  <p>My question is, for me to run it locally where do I need to place this connection string set? and what extra settings do I need to do?</p>
  <p>Thank You,</p>