# MentorGridOptions class

> The MentorGridOptions class of Novior.MentorAgent.Abstractions.Interfaces: How MentorGridExtensions.RegisterGrid reads a grid. A column is named by its…

- URL: https://docs.mentoragent.net/api/novior-mentoragent-abstractions-interfaces/mentorgridoptions
- Verified with: MentorAgent 1.5.0
- Last updated: 2026-11-26
- Packages: Novior.MentorAgent.Abstractions

How [`MentorGridExtensions.RegisterGrid`](https://docs.mentoragent.net/api/novior-mentoragent-abstractions-interfaces/mentorgridextensions#registergrid) reads a grid. A column is named by its property, as written in the row (`nameof(Order.Total)`) or as the model sees it (`total`); a name that is no column of the grid throws when the grid is registered.

## Definition

Namespace: `Novior.MentorAgent.Abstractions.Interfaces`. Package: `Novior.MentorAgent.Abstractions`.

`public sealed class MentorGridOptions`

```shell
dotnet add package Novior.MentorAgent.Abstractions
```

## Constructors

`public MentorGridOptions()`

## Properties

### `Filter`

`public bool Filter { get; set; }`

Whether the grid has a filter field in the page, `data-mentor-id="<grid>.filter"`: then the model gets `filter_<grid>`, and opening a row writes its key there first when the row is not shown. True by default.

## Methods

### `IncludeSensitive`

`public MentorGridOptions IncludeSensitive(params string[] columns)`

Lets these sensitive columns be sorted by, which a grid leaves out unless they are named here. A sensitive column is never the grid's key: the model would have to write its value to open a row.

### `Selector`

`public MentorGridOptions Selector(string part, string selector)`

The CSS selector of a part of the grid in the page, in place of its `data-mentor-id`. The part is what follows `"<grid>."` in that `data-mentor-id`: `row` (the rows), `cell.<key>` (the key's cell, inside a row), `open` (what opens a row, inside it), `filter`, or `sort.<column>` (the header clicked to sort by the column). A grid whose rows and headers take no attribute, such as a `QuickGrid`, is given its selectors here.

### `Sortable`

`public MentorGridOptions Sortable(params string[] columns)`

The columns the grid sorts by, in place of all its columns of a simple type that are not sensitive. None: the model gets no `sort_<grid>`, because the page sorts by nothing.

---

- Previous: [MentorGridExtensions class](https://docs.mentoragent.net/api/novior-mentoragent-abstractions-interfaces/mentorgridextensions.md)
- Next: [UIActionRegistration record](https://docs.mentoragent.net/api/novior-mentoragent-abstractions-interfaces/uiactionregistration.md)
