# ScrollBarExtensions

Namespace: **Wisej.Web.Markup**

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

Adds [fluent markup](https://learn.microsoft.com/en-us/dotnet/communitytoolkit/maui/markup/markup) extension methods to the [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar) class.

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

```csharp
public class ScrollBarExtensions
```

{% endtab %}

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

```visual-basic
Public Class ScrollBarExtensions
```

{% endtab %}
{% endtabs %}

## Methods

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-e4f8ed47a52590951f725a10c269555e81d41d81%2Fstatic.png?alt=media) LargeChange\<TScrollBar>(scrollBar, value)

Sets the LargeChange property of the specified [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar).

| Parameter      | Type                                                                                                      | Description                                                                                                        |
| -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| **TScrollBar** |                                                                                                           | The type of the scroll bar, must inherit from [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar). |
| **scrollBar**  | [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions) | The scroll bar for which to set the LargeChange property.                                                          |
| **value**      | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)                                               | The value to set for the large increment of the scroll bar.                                                        |

**Returns:** [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions). The modified scroll bar with the updated LargeChange property.

This method allows you to specify the amount by which the scroll box moves in response to a large scroll command.

```csharp

myScrollBar.LargeChange(10);

```

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-e4f8ed47a52590951f725a10c269555e81d41d81%2Fstatic.png?alt=media) Maximum\<TScrollBar>(scrollBar, value)

Sets the Maximum property of the specified [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar).

| Parameter      | Type                                                                                                      | Description                                                                                                        |
| -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| **TScrollBar** |                                                                                                           | The type of the scroll bar, must inherit from [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar). |
| **scrollBar**  | [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions) | The scroll bar for which to set the Maximum property.                                                              |
| **value**      | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)                                               | The maximum value for the scroll bar.                                                                              |

**Returns:** [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions). The modified scroll bar with the updated Maximum property.

This method allows you to specify the maximum value of the scroll bar.

```csharp

myScrollBar.Maximum(100);

```

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-e4f8ed47a52590951f725a10c269555e81d41d81%2Fstatic.png?alt=media) Minimum\<TScrollBar>(scrollBar, value)

Sets the Minimum property of the specified [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar).

| Parameter      | Type                                                                                                      | Description                                                                                                        |
| -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| **TScrollBar** |                                                                                                           | The type of the scroll bar, must inherit from [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar). |
| **scrollBar**  | [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions) | The scroll bar for which to set the Minimum property.                                                              |
| **value**      | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)                                               | The minimum value for the scroll bar.                                                                              |

**Returns:** [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions). The modified scroll bar with the updated Minimum property.

This method allows you to specify the minimum value of the scroll bar.

```csharp

myScrollBar.Minimum(0);

```

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-e4f8ed47a52590951f725a10c269555e81d41d81%2Fstatic.png?alt=media) OnValueChanged\<TScrollBar>(scrollBar, action)

Sets the AutoHide property of the specified [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar).

| Parameter      | Type                                                                                                      | Description                                                                                                        |
| -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| **TScrollBar** |                                                                                                           | The type of the scroll bar, must inherit from [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar). |
| **scrollBar**  | [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions) | The scroll bar for which to set the AutoHide property.                                                             |
| **action**     | [Action\<TScrollBar>](https://docs.microsoft.com/dotnet/api/system.action-1)                              | Event handler.                                                                                                     |

**Returns:** [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions). The modified scroll bar with the updated AutoHide property.

This method allows you to specify whether the scroll bar should automatically hide when not in use.

```csharp

myScrollBar.AutoHide(true);

```

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-e4f8ed47a52590951f725a10c269555e81d41d81%2Fstatic.png?alt=media) SmallChange\<TScrollBar>(scrollBar, value)

Sets the SmallChange property of the specified [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar).

| Parameter      | Type                                                                                                      | Description                                                                                                        |
| -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| **TScrollBar** |                                                                                                           | The type of the scroll bar, must inherit from [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar). |
| **scrollBar**  | [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions) | The scroll bar for which to set the SmallChange property.                                                          |
| **value**      | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)                                               | The value to set for the small increment of the scroll bar.                                                        |

**Returns:** [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions). The modified scroll bar with the updated SmallChange property.

This method allows you to specify the amount by which the scroll box moves in response to a small scroll command.

```csharp

myScrollBar.SmallChange(1);

```

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-e4f8ed47a52590951f725a10c269555e81d41d81%2Fstatic.png?alt=media) Value\<TScrollBar>(scrollBar, value)

Sets the Value property of the specified [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar).

| Parameter      | Type                                                                                                      | Description                                                                                                        |
| -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| **TScrollBar** |                                                                                                           | The type of the scroll bar, must inherit from [ScrollBar](https://docs.wisej.com/api/wisej.web/content/scrollbar). |
| **scrollBar**  | [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions) | The scroll bar for which to set the Value property.                                                                |
| **value**      | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)                                               | The value to set for the scroll bar's position.                                                                    |

**Returns:** [TScrollBar](https://docs.wisej.com/api/wisej.web.markup/extensions/wisej.web.markup.scrollbarextensions). The modified scroll bar with the updated Value property.

This method allows you to specify the current position of the scroll box on the scroll bar.

```csharp

myScrollBar.Value(50);

```
