count property
Returns the count of named ranges.
final Workbook workbook = Workbook();
final Worksheet worksheet = workbook.worksheets[0];
worksheet.getRangeByName('A1:D4').setText('Hello');
final Range range1 = worksheet.getRangeByName('A1:C1');
final Range range2 = worksheet.getRangeByName('A2:C2');
workbook.names.add('Title', range1);
worksheet.names.add('Body', range2);
final int sheetCount = worksheet.names.count;
final int bookCount = workbook.names.count;
workbook.dispose();
Implementation
late int count;