自定义WEB控件时,自定义的事件无法触发,麻烦大家帮我看看

ryxstar 2008-06-30 10:51:38
<DefaultProperty("Text"), ToolboxData(" <{0}:NewDataGrid runat=server> </{0}:NewDataGrid>")> Public Class NewDataGrid
Inherits System.Web.UI.WebControls.WebControl
Public Event BindMyGrid(ByVal sender As Object, ByVal e As System.EventArgs)

public Function FillDataGrid() As Boolean

RaiseEvent BindMyGrid(Me, New EventArgs())
end function
end class


在应用该控件时,无法触发该事件,为什么啊
Private Sub NewDataGrid1_BindMyGrid(ByVal sender As Object, ByVal e As EventArgs) Handles NewDataGrid1.BindMyGrid
response.write('a');
End Sub
...全文
36 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
gyc 2008-06-30
  • 打赏
  • 举报
回复
Web比较特别
要引发事件 ,必须激活自动回调

16,717

社区成员

发帖
与我相关
我的任务
社区描述
VB技术相关讨论,主要为经典vb,即VB6.0
社区管理员
  • VB.NET
  • 水哥阿乐
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧