Property: Count for Sheets
- Updated2024-09-12
- 1 minute(s) read
DataPlugin > Properties > Property: Count for Sheets
Property: Count for Sheets
Returns the number of worksheets in a workbook.
Object.Count
Object | Sheets Object with this property |
Object.Count | LongInteger with read access |
The following example generates for each worksheet a new channel group. The channel group receives the name of the worksheet and a property which retains the position of the worksheet in the workbook.
Dim i, oCurrSheet, oNewGroup For i = 1 to Workbook.Sheets.Count Set oCurrSheet = Workbook.Sheets(i) Set oNewGroup = Root.ChannelGroups.Add(oCurrSheet.Name) Call NewGroup.Properties.Add("Description", "Sheet"&oCurrSheet.Index) Next