officefileapi-devexpress-dot-spreadsheet-dot-columncollection-dot-hide-x28-system-dot-int32-system-dot-int32-x29.md
Hides the specified columns in a worksheet.
Namespace : DevExpress.Spreadsheet
Assembly : DevExpress.Spreadsheet.v25.2.Core.dll
NuGet Package : DevExpress.Spreadsheet.Core
void Hide(
int first,
int last
)
Sub Hide(
first As Integer,
last As Integer
)
| Name | Type | Description |
|---|---|---|
| first | Int32 |
A zero-based integer representing the index of the first column to be hidden.
| | last | Int32 |
A zero-based integer representing the index of the last column to be hidden.
|
Use the Hide method to hide multiple columns at once. To hide an individual column, use the Column.Visible property.
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Hide(Int32, Int32) method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
// Hide columns from 5 to 7.
worksheet.Columns.Hide(5, 7);
// Hide rows from 6 to 8.
' Hide columns from 5 to 7.
worksheet.Columns.Hide(5, 7)
' Hide rows from 6 to 8.
See Also