在Python中显示或隐藏滚动条
Contents
[
Hide
]
Aspose.Cells - 显示或隐藏滚动条
隐藏行/列标头
要使用Aspose.Cells Java for Python隐藏行/列标题,请调用DisplayHideRowColumnHeaders 模块。
Python 代码
workbook = self.Workbook(self.dataDir + "Book1.xls")
#Hiding the vertical scroll bar of the Excel file
workbook.getSettings().setVScrollBarVisible(False)
#Hiding the horizontal scroll bar of the Excel file
workbook.getSettings().setHScrollBarVisible(False)
#Saving the modified Excel file in default (that is Excel 2003) format
workbook.save(self.dataDir + "output.xls")
\# Print message
print "Scroll bars are now hidden, please check the output document."
使行/列标头可见
通过使用工作表类的setRowColumnHeadersVisible(true)方法,使行和列标题可见。
Python 代码
# Displaying the headers of rows and columns
worksheet.setRowColumnHeadersVisible(true)
下载运行代码
从以下任何社交编码网站下载Hello World(Aspose.Cells)