السلام عليكم ورحمة الله وبركاته
تظهر لي ياشباب رسالة الخطأ التالية عند تنفيذ الصفحة رغم أن الربط في ظني صحيح
Server Error in '/WebApplication1' Application. -------------------------------------------------------------------------------- Login failed for user 'ALQADHI\ASPNET'. 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: Login failed for user 'ALQADHI\ASPNET'. Source Error: Line 91: 'Put user code to initialize the page here Line 92: If Not IsPostBack Then Line 93: SqlDataAdapter1.Fill(DataSet11, "author") Line 94: Line 95: DataGrid1.DataBind() Source File: C:\Inetpub\wwwroot\WebApplication1\WebForm1.aspx.vb Line: 93 Stack Trace: [SqlException: Login failed for user 'ALQADHI\ASPNET'.] System.Data.SqlClient.ConnectionPool.GetConnection(Boolean& isInTransaction) System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnectionString options, Boolean& isInTransaction) System.Data.SqlClient.SqlConnection.Open() System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection connection, ConnectionState& originalState) System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable) WebApplication1.WebForm1.Page_Load(Object sender, EventArgs e) in C:\Inetpub\wwwroot\WebApplication1\WebForm1.aspx.vb:93 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.573; ASP.NET Version:1.1.4322.573
وهذا الكود المستخدم في عملية الربط
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'Put user code to initialize the page here If Not IsPostBack Then SqlDataAdapter1.Fill(DataSet11, "author") DataGrid1.DataBind() End If End Sub End Class
الربط نجح معي تماما في تطبيقات الويندوز في في asp فشل ليش مش عارف .
فلو ممكن توضحوا لي الخطأ والطريقة الصحيحة للربط .