请教-----Handles 子句要求一个在包含类型或它的某个基类型中定义的 WithEvents 变量
在VS2005中运行的网页出现这个错误“Handles 子句要求一个在包含类型或它的某个基类型中定义的 WithEvents 变量”,请教应该怎么解决?谢谢^_^ Partial Class newsAdminDetail
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Request.QueryString("action") = "Insert" Then
CType(LoginView1.FindControl("DetailsView1"), DetailsView).DefaultMode = DetailsViewMode.Insert
End If
End Sub
Protected Sub AccessDataSource1_Inserted(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.SqlDataSourceStatusEventArgs) Handles AccessDataSource1.Inserted
Response.Redirect("newsAdmin.aspx")
End Sub
Protected Sub AccessDataSource1_Updated(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.SqlDataSourceStatusEventArgs) Handles AccessDataSource1.Updated
Response.Redirect("newsAdmin.aspx")
End Sub
End Class
在AccessDataSource1下面有波浪线,可能就是这里有问题,但不知应该怎么更改~~