# DataGridViewToolClickEventArgs

Namespace: **Wisej.Web**

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

* [DataGridViewCellEventArgs](/api/wisej.web/lists-and-grids/datagridview/wisej.web.datagridviewcelleventargs.md)
  * [DataGridViewToolClickEventArgs](/api/wisej.web/lists-and-grids/datagridview/wisej.web.datagridviewtoolclickeventargs.md)

Provides data for the [CellToolClick](/api/wisej.web/lists-and-grids/datagridview.md#celltoolclick) event.

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

```csharp
public class DataGridViewToolClickEventArgs : DataGridViewCellEventArgs
```

{% endtab %}

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

```visual-basic
Public Class DataGridViewToolClickEventArgs
    Inherits DataGridViewCellEventArgs
```

{% endtab %}
{% endtabs %}

## Constructors

### ![](/files/hsR4ok3152WyAf8J2C1u) DataGridViewToolClickEventArgs(item, columnIndex, rowIndex)

Initializes a new instance of the [ToolClickEventArgs](/api/wisej.web/editors/wisej.web.toolclickeventargs.md) class for the clicked [ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md).

| Name            | Type                                                               | Description                                                                                    |
| --------------- | ------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------- |
| **item**        | [ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md) | The [ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md) to store in this event. |
| **columnIndex** | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)        | The index of the column containing the cell that the event occurs for.                         |
| **rowIndex**    | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)        | The index of the row containing the cell that the event occurs for.                            |

**Throws:**

* [ArgumentOutOfRangeException](https://docs.microsoft.com/dotnet/api/system.argumentoutofrangeexception) *columnIndex* is less than -1, or *rowIndex* is less than -1.

### ![](/files/hsR4ok3152WyAf8J2C1u) DataGridViewToolClickEventArgs(item, cellAddress)

Initializes a new instance of the [ToolClickEventArgs](/api/wisej.web/editors/wisej.web.toolclickeventargs.md) class for the clicked [ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md).

| Name            | Type                                                                | Description                                                                                    |
| --------------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- |
| **item**        | [ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md)  | The [ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md) to store in this event. |
| **cellAddress** | [Point](https://docs.microsoft.com/dotnet/api/system.drawing.point) | The address of the cell that the event occurs for                                              |

**Throws:**

* [ArgumentOutOfRangeException](https://docs.microsoft.com/dotnet/api/system.argumentoutofrangeexception) *cellAddress.X.X* is less than -1, or *cellAddress.Y.Y* is less than -1.

## Properties

### ![](/files/hsR4ok3152WyAf8J2C1u) Tool

[ComponentTool](/api/wisej.web/editors/wisej.web.componenttool.md): Returns the clicked tool item.

## Used By

| Name                                                                                                                            | Description                                                                                                                     |
| ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| [DataGridViewToolClickEventHandler](/api/wisej.web/lists-and-grids/datagridview/wisej.web.datagridviewtoolclickeventhandler.md) | Represents the method that will handle the [CellToolClick](/api/wisej.web/lists-and-grids/datagridview.md#celltoolclick) event. |


---

# 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.datagridviewtoolclickeventargs.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.
