---
title: "Event Handling  in C#"  
description: "This blog talks about the Event Handling in c#.  An event is an action such as mouse click, a key press, mouse movement or any system-generated notifi"  
author: "priyanka kushwaha"  
published: 2015-02-16  
updated: 2015-02-16  
canonical: https://www.mindstick.com/blog/765/event-handling-in-c-sharp  
category: ".net"  
tags: ["c#", "asp.net"]  
reading_time: 1 minute  

---

# Event Handling  in C#

This blog talks about the [Event Handling](https://www.mindstick.com/articles/12724/event-handling-in-android) in c#.\

An event is an action such as mouse click, a key press, [mouse movement](https://www.mindstick.com/forum/12836/rotate-div-with-mouse-movement-in-html-css-and-javacript) or any system-generated notification. A process communicates through events.

Event is ASP.NET raised at the client machine and handled at the server machine. For example, a [user clicks](https://answers.mindstick.com/qa/34556/if-a-user-clicks-all-the-google-ads-on-my-site-is-it-foul) a buttons displayed in the browser. A [click event](https://www.mindstick.com/forum/424/how-to-call-form_paint-event-on-button-click-event) is raised. The browser handles this client-side event by posting it to the server.

The server has a subroutine describing what to do when the event is raised. It is called the event-handler. Therefore, when the event message is transmitted to the server. It checks whether the click event has an associated [event handler](https://www.mindstick.com/forum/1371/c-sharp-dot-net-event-handler-delegate-question).

##### Event Arguments:

ASP.NET [event handlers](https://www.mindstick.com/forum/2155/imagebutton-with-mouse-event-handlers-considered-not-well-formed) generally take two [parameters](https://www.mindstick.com/articles/87/passing-parameters-in-c-sharp) and return void. The first [parameter](https://www.mindstick.com/blog/450/parameter-class-in-c-sharp) represents the object raising the event and the second parameter is event argument.

##### Syntax of an event is:

Void Event name(Object sender, EventArgs e)\
You want to learn [event delegate](https://www.mindstick.com/forum/333/how-to-understand-and-use-the-event-delegate) What is Event delegate?

---

Original Source: https://www.mindstick.com/blog/765/event-handling-in-c-sharp

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
