Delegates are alse used as callbacks so that one class can say to another "do this work and when you're done, let me know"就这个,哪位能举个小例子啊?

解决方案 »

  1.   

    呵,and when you're done, let me know我想知道的是关于这个的。而不是delegate或event的基本常识。阿门。应该是关于callback的吧~
      

  2.   

    参见:<<C# Delegate 简介>>
    http://www.chinaaspx.com/article/csharp/355.htm
      

  3.   

    那你看看异步调用的例子,其中一种方式就是提供一个callback函数,异步调用模式定义AsyncCallback 委托,你把你在处理结束时希望调用的方法加入该委托,进行异步调用,处理结束后应用程序框架会自动调用该方法。