# DataGridViewCellMouseEventHandler

Namespace: **Wisej.Web**

Assembly: **Wisej.Framework** (4.0.0.0)

Represents the method that will handle mouse-related events raised by a [DataGridView](/api/wisej.web/lists-and-grids/datagridview.md).

{% tabs %}
{% tab title="C#" %}

```csharp
public delegate void DataGridViewCellMouseEventHandler(Object sender, DataGridViewCellMouseEventArgs e)
```

{% endtab %}

{% tab title="VB.NET" %}

```visual-basic
Public Delegate Sub DataGridViewCellMouseEventHandler(ByVal sender As [Object], ByVal e As DataGridViewCellMouseEventArgs)
```

{% endtab %}
{% endtabs %}

## Parameters

| Name       | Type                                                                                                                      | Description                                                                                                                                               |
| ---------- | ------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **sender** | [Object](https://docs.microsoft.com/dotnet/api/system.object)                                                             | The source of the event.                                                                                                                                  |
| **e**      | [DataGridViewCellMouseEventArgs](/api/wisej.web/lists-and-grids/datagridview/wisej.web.datagridviewcellmouseeventargs.md) | A [DataGridViewCellMouseEventArgs](/api/wisej.web/lists-and-grids/datagridview/wisej.web.datagridviewcellmouseeventargs.md) that contains the event data. |

## Fired By

| Name                                                                                                                     | Description                                                                                                         |
| ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------- |
| [DataGridView.CellMouseClick](/api/wisej.web/lists-and-grids/datagridview.md#cellmouseclick)                             | Occurs whenever the user clicks anywhere on a cell with the mouse.                                                  |
| [DataGridView.CellMouseDoubleClick](/api/wisej.web/lists-and-grids/datagridview.md#cellmousedoubleclick)                 | Fired when a cell within the [DataGridView](/api/wisej.web/lists-and-grids/datagridview.md) is double-clicked.      |
| [DataGridView.CellMouseDown](/api/wisej.web/lists-and-grids/datagridview.md#cellmousedown)                               | Fired when the user presses a mouse button while the pointer is within the boundaries of a cell.                    |
| [DataGridView.CellMouseMove](/api/wisej.web/lists-and-grids/datagridview.md#cellmousemove)                               | Fired when the mouse pointer moves over the [DataGridView](/api/wisej.web/lists-and-grids/datagridview.md) control. |
| [DataGridView.CellMouseUp](/api/wisej.web/lists-and-grids/datagridview.md#cellmouseup)                                   | Fired when the user releases a mouse button while over a cell.                                                      |
| [DataGridView.ColumnHeaderMouseClick](/api/wisej.web/lists-and-grids/datagridview.md#columnheadermouseclick)             | Fired when the user clicks a column header.                                                                         |
| [DataGridView.ColumnHeaderMouseDoubleClick](/api/wisej.web/lists-and-grids/datagridview.md#columnheadermousedoubleclick) | Fired when a column header is double-clicked.                                                                       |
| [DataGridView.RowHeaderMouseClick](/api/wisej.web/lists-and-grids/datagridview.md#rowheadermouseclick)                   | Fired when the user clicks within the boundaries of a row header.                                                   |
| [DataGridView.RowHeaderMouseDoubleClick](/api/wisej.web/lists-and-grids/datagridview.md#rowheadermousedoubleclick)       | Fired when a row header is double-clicked.                                                                          |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.wisej.com/api/wisej.web/lists-and-grids/datagridview/wisej.web.datagridviewcellmouseeventhandler.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
