Windows Application - SPLessons

Win App Event Handling

Home > Lesson > Chapter 23
SPLessons 5 Steps, 3 Clicks
5 Steps - 3 Clicks

Win App Event Handling

Windows Application Event Handling

Event

shape Description

An Event is a message, which is generated by an object. The object is created by the user actions. The object which generates the event is called as "Event Sender". For example
  • Clicking a mouse is also an event.
  • Pressing keyboard button is also an event.

Mouse Events

shape Description

Mouse Events are raised due to the Mouse. That means if the user performs any action through the mouse, Then the events which are raised are called as Mouse Events.

shape Example

Clicking a mouse is a mouse event. See the below code to know about the button Click event which is mouse event. [csharp]private void button1_Click(object sender, EventArgs e) { }[/csharp]

Keyboard Events

shape Description

Keyboard Events are raised due to the Keyboard. That means if the user performs any action through the Keyboard, then the events which are raised are called as keyboard  Events.

shape Example

Pressing a keyboard button is a keyboard event. The following things can be explained in the later chapters.
  • How to raise events?
  • What are the different mouse and keyboard events?