Hosting ASP.net app on somee - database update from C# app

Status
Not open for further replies.

north2012

Member level 3
Joined
Apr 1, 2013
Messages
63
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Activity points
1,813
have ASP.NET app with database which is updated by C# application, so database is placed on my local disc. .NET app can only read entries (changes are not allowed). I can run my .NET app from local host (from Visual Studio or/and IIS) or other computer in network by ipaddressort_number/page_name.aspx. Everything is working fine.

But now I would like to publish my app on somee. I made account and in the same project I added one simple page (just plain text) and that page can be accessed my other computers fron Internet by typing myusername.somee.com/that_simple_page_name.aspx I found a lot of similar topics on the Internet forums so I made changes: - TCP/IP enabled in SQL Server Configuration Manager - exceptions ports 1433 and 1434 (UDP), - SQL Server Browser enabled...

I made .zip of folder created during IIS publishing (c:\inetpub\wwwroot\My_App_name) and uploaded it to the some by File Manager Upload. But when I tried to access to the page with readings from database I got error:

"Server Error in '/' Application. A network-related or instance-specific error occurred while establishing a connection to SQL Server. 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) Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException: A network-related or instance-specific error occurred while establishing a connection to SQL Server. 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)"

I believe that problem is with my connection string. My current connection string (web config file uploaded to the somee and on my Visual Studio 2013 Ultimate) is:

Code:
<connectionStrings>
<add name="_web_server_test.Properties.Settings.Base1ConnectionString"
connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename="C:\Database Somee web\Base1.mdf";Integrated Security=True;Connect Timeout=30"
providerName="System.Data.SqlClient" />
</connectionStrings>


Can you recognize what is the problem and how to change connection string?

Thanks.
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…