---
description: Wisej.Web.TableLayoutColumnStyleCollection
---

# TableLayoutColumnStyleCollection

Namespace: **Wisej.Web**

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

* [TableLayoutStyleCollection](wisej.web.tablelayoutstylecollection)
  * [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection)

A collection that stores [ColumnStyle](wisej.web.columnstyle) objects.

{% tabs %}
{% tab title="C#" %}
```csharp
public class TableLayoutColumnStyleCollection : TableLayoutStyleCollection
```
{% endtab %}

{% tab title="VB.NET" %}
```visual-basic
Public Class TableLayoutColumnStyleCollection
    Inherits TableLayoutStyleCollection
```
{% endtab %}
{% endtabs %}

## Properties

### ![](https://314832588-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MTHCfAYyBPycFG90wsw-4198400543%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media\&token=060b281d-9363-48a1-a0f9-788ad1831e96)Item(index)

[ColumnStyle](wisej.web.columnstyle): Returns or sets the [ColumnStyle](wisej.web.columnstyle) at the specified index.

## Methods

### ![](https://314832588-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MTHCfAYyBPycFG90wsw-4198400543%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media\&token=060b281d-9363-48a1-a0f9-788ad1831e96)Add(colStyle)

Adds a new [ColumnStyle](wisej.web.columnstyle) to the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection).

| Parameter    | Type                                 | Description                                                                                                                            |
| ------------ | ------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------- |
| **colStyle** | [ColumnStyle](wisej.web.columnstyle) | The [ColumnStyle](wisej.web.columnstyle) to add to the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection). |

**Returns:** [Int32](https://docs.microsoft.com/en-us/dotnet/api/system.int32). The position into which the new element was inserted.

### ![](https://314832588-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MTHCfAYyBPycFG90wsw-4198400543%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media\&token=060b281d-9363-48a1-a0f9-788ad1831e96)Contains(colStyle)

Determines whether the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection) contains a specific style.

| Parameter    | Type                                 | Description                                                                                                                               |
| ------------ | ------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------- |
| **colStyle** | [ColumnStyle](wisej.web.columnstyle) | The [ColumnStyle](wisej.web.columnstyle) to locate in the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection). |

**Returns:** [Boolean](https://docs.microsoft.com/en-us/dotnet/api/system.boolean). true if the [ColumnStyle](wisej.web.columnstyle) is found in the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection); otherwise, false.

### ![](https://314832588-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MTHCfAYyBPycFG90wsw-4198400543%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media\&token=060b281d-9363-48a1-a0f9-788ad1831e96)IndexOf(colStyle)

Determines the index of a specific item in the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection).

| Parameter    | Type                                 | Description                                                                                                                               |
| ------------ | ------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------- |
| **colStyle** | [ColumnStyle](wisej.web.columnstyle) | The [ColumnStyle](wisej.web.columnstyle) to locate in the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection). |

**Returns:** [Int32](https://docs.microsoft.com/en-us/dotnet/api/system.int32). The index of _colStyle_ if found in the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection); otherwise, -1.

### ![](https://314832588-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MTHCfAYyBPycFG90wsw-4198400543%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media\&token=060b281d-9363-48a1-a0f9-788ad1831e96)Insert(index, colStyle)

Inserts a [ColumnStyle](wisej.web.columnstyle) into the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection) at the specified position.

| Parameter    | Type                                                              | Description                                                                                                                                                        |
| ------------ | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **index**    | [Int32](https://docs.microsoft.com/en-us/dotnet/api/system.int32) | The zero-based index at which the [ColumnStyle](wisej.web.columnstyle) should be inserted.                                                                         |
| **colStyle** | [ColumnStyle](wisej.web.columnstyle)                              | The [ColumnStyle](wisej.web.columnstyle) to insert into the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection). The value can be null. |

### ![](https://314832588-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MTHCfAYyBPycFG90wsw-4198400543%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media\&token=060b281d-9363-48a1-a0f9-788ad1831e96)Remove(colStyle)

Removes the first occurrence of a specific object from the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection).

| Parameter    | Type                                 | Description                                                                                                                                                        |
| ------------ | ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **colStyle** | [ColumnStyle](wisej.web.columnstyle) | The [ColumnStyle](wisej.web.columnstyle) to remove from the [TableLayoutColumnStyleCollection](wisej.web.tablelayoutcolumnstylecollection). The value can be null. |
