什么是事件在C#中?事件

2023-09-03 20:57:45 作者:我叫坚强

在C#是什么事件?它是类似于 ActionScript事件?是不是有什么不同?在哪?

解决方案   

在C#中的事件是一种一类   提供通知给客户   该上课的时候​​一些有趣的事情   恰好一个对象。最多   熟悉使用的事件是在   图形用户界面;通常情况下,   即重新present控件类   该接口有那些事件   当用户做一些事情通知   以控制(例如,单击   按钮)。

本教程介绍了如何声明,调用和挂钩的事件在C#中的 http://msdn.microsoft.com/en-us/library/aa645739%28VS.71%29.aspx

in c# what is Event? Is it similar to ActionScript Event ? Is it different? In what?

解决方案 c 事件 event

An event in C# is a way for a class to provide notifications to clients of that class when some interesting thing happens to an object. The most familiar use for events is in graphical user interfaces; typically, the classes that represent controls in the interface have events that are notified when the user does something to the control (for example, click a button).

This tutorial shows how to declare, invoke, and hook up to events in C# http://msdn.microsoft.com/en-us/library/aa645739%28VS.71%29.aspx