0
df = pd.read_excel("file_name.xlsb", sheet_name="sheetname")

Is it possible to check the df (DataFrame) visibility.

I have read the excel file (.xlsb) using pandas. I cannot use other libraries to check the sheet visibility. Since, I shall be do more changes if I change the library.

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Vineesh TP
  • 7,755
  • 12
  • 66
  • 130

1 Answers1

0

Using this code you can see if the sheet is hidden or not

import pandas as pd

xls = pd.ExcelFile('file_name.xlsb')

sheets = xls.book.sheets()

for sheet in sheets:
    print(sheet.name, sheet.visibility)
kynnemall
  • 855
  • 9
  • 26