Hi,
I am a new member. Hello to every one. I am new in ASP.NET area. I wrote an ASP.NET web application which was running ok with my old laptop. Currently I have given a new laptop. Now I copied my application to the new laptop and I am experiencing as SQL Server connection error: "SQL Server does not exist or access denied". Following is a simply ASP.NET application to test the connection and I am getting following error:
For your information I am using SQL Server 2000 and Microsoft Visual Studio .NET 2003 and ASP.NET Version:1.1.4322.2032 .
I can connection to the SQL Server using a DataLinks file.
Also I have copied an existing windows C# application from my old laptop where the SQL Server connection working fine.
Thank you for your help in advance.
Atia
************************************************** *************************************
Server Error in '/testsqlconn' Application.
--------------------------------------------------------------------------------
SQL Server does not exist or access denied.
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: SQL Server does not exist or access denied.
Source Error:
Line 23:
Line 24: SqlConnection conn = new SqlConnection("UID=batch;PWD=bbatch;Initial Catalog=TEST;Data Source=NWHEXPRESS");
Line 25: conn.Open();
Line 26: conn.Close();
Line 27:
Source File: c:\inetpub\wwwroot\testsqlconn\testsqlconn.aspx.cs Line: 25
Stack Trace:
[SqlException: SQL Server does not exist or access denied.]
System.Data.SqlClient.ConnectionPool.GetConnection (Boolean& isInTransaction)
System.Data.SqlClient.SqlConnectionPoolManager.Get PooledConnection(SqlConnectionString options, Boolean& isInTransaction)
System.Data.SqlClient.SqlConnection.Open()
testsqlconn.WebForm1.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\testsqlconn\testsqlconn.aspx.cs :25
System.Web.UI.Control.OnLoad(EventArgs e)
System.Web.UI.Control.LoadRecursive()
System.Web.UI.Page.ProcessRequestMain()
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2032; ASP.NET Version:1.1.4322.2032
************************************************** *********************