Get worksheet unique id

How to Get worksheet unique id

Aspose.Cells for Python via .NET provides the ability to get the unique id of a worksheet by using the Worksheet.unique_id property. The following code snippet demonstrates the use of the Worksheet.unique_id property to print the unique id of a worksheet. The following code snippet uses this sample excel file.

Source Code

from aspose.cells import Workbook
# Source directory
sourceDir = "./"
# Load source Excel file
workbook = Workbook(sourceDir + "Book1.xlsx")
# Access first worksheet
worksheet = workbook.worksheets[0]
# Print Unique Id
print("Unique Id: " + worksheet.unique_id)