匿名方法代码示例
string text = "Yeah, you clicked the button!";
EventHandler handler =delegate(object dlgSender, EventArgs dlgE)
{
Response.Write(text);
};
this.Button1.Click += handler;
EventHandler handler =delegate(object dlgSender, EventArgs dlgE)
{
Response.Write(text);
};
this.Button1.Click += handler;
posted on 2004-10-26 09:35 Goodspeed 阅读(1138) 评论(0) 编辑 收藏 举报