# Showing or Hiding Rows or Columns

Spread for ASP.NET allows you to hide a row or column so that it is not visible to the user. You can also hide only the row headers or column headers in a sheet.

## Content

You can hide a row or column so that it is not visible to the user. You can also hide only the row headers or column headers; follow the procedures in [Showing or Hiding Headers](/spreadnet/docs/latest/online-asp/overview/spweb-devguide/spweb-appearSet/spweb-appearHeader/spweb-HeaderHide).
When you hide a row or column, the value of the row height or column width is kept by the fpSpread component. If you display the row or column again, it is displayed at the value it was before it was hidden. The data is still available to other parts of the sheet; the only change is that the row or column is not displayed.
If you want to remove the row or column, refer to [Removing a Row or Column](/spreadnet/docs/latest/online-asp/overview/spweb-devguide/spweb-appearSet/spweb-appearRowCol/spweb-RowColRemove).

## Using a Shortcut

Set the [Visible](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.Row.Visible.html) property for the [Row](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.Row.html) shortcut object or the [Visible](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.Column.Visible.html) property for the [Column](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.Column.html) shortcut object, or use the [SetRowVisible](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.SheetView.SetRowVisible.html) or [SetColumnVisible](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.SheetView.SetColumnVisible.html) method in the [SheetView](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.SheetView.html) object.
**Example**
This example code hides the second row and hides the third column.

```csharp
FpSpread1.Sheets[0].SetRowVisible(1, false);
FpSpread1.Sheets[0].SetColumnVisible(2, false);
```

```vbnet
FpSpread1.Sheets[0].SetRowVisible(1, false)
FpSpread1.Sheets[0].SetColumnVisible(2, false)
```

## Using Code

Set the [SetRowVisible](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.SheetView.SetRowVisible.html) or [SetColumnVisible](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.SheetView.SetColumnVisible.html) method in the [SheetView](/spreadnet/api/latest/online-asp/FarPoint.Web.Spread/FarPoint.Web.Spread.SheetView.html) object.
**Example**
This example code sets the first sheet to have 100 rows and 10 columns.

```csharp
FarPoint.Web.Spread.SheetView sv;
sv = FpSpread1.ActiveSheetView;
sv.SetRowVisible(1, false);
sv.SetColumnVisible(2, false);
```

```vbnet
Dim sv As FarPoint.Web.Spread.SheetView
sv = FpSpread1.ActiveSheetView
sv.SetRowVisible(1, False)
sv.SetColumnVisible(2, false)
```

## Using the Spread Designer

1. In Spread Designer, select the row or column.
2. In the properties window, set the **Visible** property to false.
3. Click **Apply and Exit** to close the Spread Designer.