السلام عليكم
اريد على مستوى المشروع طول ما المشروع شغال ان يقوم باسترجاع بيانات من الداتا بيز لعمل تحديث عليها مثلا
فحاولت من خلال فى ملف ال global.asax
فى حدث application_start
ولكن المشكلة فى جملة الconn
انا اكتب
Private conn As SqlConnection = New System.Data.SqlClient.SqlConnection(ConfigurationSettings.AppSettings("webconfig"))ولكن تظهر الارور الاتى:
An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) 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: An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) Source Error: Line 14: Dim cmd As New SqlClient.SqlCommand(sql, conn) Line 15: Dim cmd_y As New SqlClient.SqlCommand(n, conn) Line 16: conn.Open() Line 17: Dim r As SqlClient.SqlDataReader = cmd.ExecuteReader() Line 18: Dim nn As Integer = cmd_y.ExecuteScalar() Source File: c:\inetpub\wwwroot\mashroo3\global.asax Line: 16 Stack Trace: