【发布时间】:2011-08-18 22:23:33
【问题描述】:
我在页面上有嵌套控件。例如:
Page
-ChildControl1 (of type AllOfMyItems)
-ChildControl2 (of type ListOfItems)
-ChildControl3 (of type MyItem <- this one fires event)
当子控件引发事件时,我希望页面处理该事件。有什么好方法可以做到这一点?
Events and delegates 在这里使用似乎是个好主意。
所以我试图在我的页面的 Page_Init 上执行以下操作:
MyItem.SomethingHappened += doStuff();
有什么好的方法可以做到这一点?
【问题讨论】:
标签: asp.net events delegates delegation