Get Started
Usage API
More information

SetVisible

SetVisible(isVisible)

Set the state of sheet visibility.

Parameters:

Name Type Description
isVisible bool

Specify if the sheet is visible or not.

Returns:

This method doesn't return any data.

Example

Copy code
builder.CreateFile("xlsx");
oWorksheet = Api.GetActiveSheet();
oWorksheet.SetVisible(true);
oWorksheet.GetRange("A1").SetValue("The current worksheet is visible.");
builder.SaveFile("xlsx", "SetVisible.xlsx");
builder.CloseFile();

Resulting document