When I tried to build the following code, I got the error.
this.Invoke(delegate()
{
Application.DoEvents();
});
I can overcome it by converting the anonymous method to a delegate:
this.Invoke(new Action(delegate() {
Application.DoEvents();
}));
More to read:
They are Anonymous Methods, not Anonymous Delegates.
http://staceyw.spaces.live.com/blog/cns!F4A38E96E598161E!1042.entry
posted @ 2009-11-24 17:47
Warren Tang 阅读(18)
评论(0) 编辑 收藏 网摘 所属分类:
dotNET