TRY NEW VERSION

Try now New API BETA

Try out the new view and capabilities of the API documentation

START

SetVisible

SetVisible(isVisible)

Sets the state of sheet visibility.

Parameters:

Name Type Description
isVisible boolean

Specifies if the sheet is visible or not.

Returns:

This method doesn't return any data.

Example

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

Resulting document