title: Getting error: A network-related or instance-specific error occurred while establishing a connection to SQL Server
body: <p>I'm newbie developer. I have a problem trying to connect to SQL Server from my computer to server machine.</p>
  
  <blockquote>
    <p>A network-related or instance-specific error occurred while establishing a connection to SQL Server.<br>
    The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)</p>
  </blockquote>
  
  <p>I've searched the way to issue it and I'm found many solution. But none are working for me. Could you please help me?</p>
  
  <p>This is my connection string</p>
  
  <pre><code>string constring = @"Data Source=137.xx.xx.xxx\\SQLEXPRESS;Initial Catalog=EDI_HR;User ID=sa;Password=1234;";
  </code></pre>
  
  <p>and </p>
  
  <pre><code>string constring = @"Data Source=CISXXXXXX\SQLEXPRESS;Initial Catalog=EDI_HR;User ID=sa;Password=1234;";
  </code></pre>
  
  <p>Finally, those are some of the references of a solution that don't work for me:</p>
  
  <ul>
  <li><a href="https://www.lansweeper.com/kb/174/a-network-related-or-instance-specific-error-occurred.html" rel="nofollow noreferrer">https://www.lansweeper.com/kb/174/a-network-related-or-instance-specific-error-occurred.html</a></li>
  <li><a href="https://support.solarwinds.com/Success_Center/Network_Performance_Monitor_(NPM)/Exception_A_network_related_or_instance_specific_error_while_establishing_a_connection_to_SQL_Server" rel="nofollow noreferrer">https://support.solarwinds.com/Success_Center/Network_Performance_Monitor_(NPM)/Exception_A_network_related_or_instance_specific_error_while_establishing_a_connection_to_SQL_Server</a></li>
  <li><a href="https://stackoverflow.com/questions/18060667/why-am-i-getting-cannot-connect-to-server-a-network-related-or-instance-speci">Why am I getting &quot;Cannot Connect to Server - A network-related or instance-specific error&quot;?</a></li>
  <li><a href="https://stackoverflow.com/questions/1391503/why-did-a-network-related-or-instance-specific-error-occur-while-establishing-a">Why did a network-related or instance-specific error occur while establishing a connection to SQL Server?</a>  </li>
  </ul>