Conection String from Visual Studio

Asked

Viewed 151 times

-1

I have a C# Asp Net application with MVC in a SQL SERVER database on the Kinghost access provider, but I can’t get the application to connect to the KH database, gives a Windows error, someone could help me.

Server Error in the '/default MVC' Application. System cannot find specified file Description: An untreated exception occurred during the execution of the current web request. Examine stack tracking for more information about the error and where it originated in the code.

Exception Details: System.ComponentModel.Win32exception: The system cannot find the specified file

Error of Origin:

Untreated exception was generated during the execution of the current web request. Information related to the origin and location of the exception can be identified using the exception stack tracking below.

Cell Trace:

[Win32exception (0x80004005): The system cannot find the file specified]

[Sqlexception (0x80131904): Instance-specific or network error to establish connection with SQL Server. The server was not found or was not accessible. Check that the instance name is correct and if SQL Server is configured to allow remote connections. (Preview: SQL Network Interfaces, error: 52 - Not possible locate a Local Database Runtime installation. Check SQL Server Express is installed correctly and if the Time feature Local Database Execution is enabled.)]
System.Data.Sqlclient.SqlInternalConnectionTds.. ctor(Dbconnectionpoolidentity Dentity, Sqlconnectionstring connectionOptions, Sqlcredential Credential, Object providerInfo, String newPassword, Securestring newSecurePassword, Boolean redirectedUserInstance, Sqlconnectionstring userConnectionOptions, Sessiondata reconnectSessionData, Dbconnectionpool, String accessToken, Boolean applyTransientFaultHandling, Sqlauthenticationprovidermanager sqlAuthProviderManager) +907

  • You read the error message? "The server was not found or not accessible. Check that the instance name is correct and that SQL Server is configured to allow remote connections".

  • The point is that I configure the KH Database on my machine by the IP past, the application running on Localhost, and recording in the KH database and works normal, but when I send the application to ftp and runs on the WEB, it tries to connect in the kh database and then gives this error.

  • Maybe your web host isn’t allowing you to reach the KH address to connect to the bank

1 answer

0

I found the problem, as used the Identity it creates the tables and another bank, now I created the tables in my bank and pointed out his default connection to the correct bank and it worked

Browser other questions tagged

You are not signed in. Login or sign up in order to post.