ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Count number of sheets (https://www.excelbanter.com/excel-discussion-misc-queries/157109-count-number-sheets.html)

JHL

Count number of sheets
 
Hello,
I have two questions. What is the limit on the number of sheets in a Excel
file? How can I count the number of sheets in a large worksheet?

Thanks,
JHL

Bernard Liengme

Count number of sheets
 
In XL2003 and XL2007: Limited by available memory (default is 3 sheets)
You find this by searching Help with the term "specs"

This UDF will tell you how many worksheets (excludes chartsheets):
Function Sheetcount()
Sheetcount = Worksheets.Count
End Function

Call it with =SHEETCOUNT()
Need help with VBA: see David McRitchie's site on "getting started" with VBA
http://www.mvps.org/dmcritchie/excel/getstarted.htm

There is also =INFO("numfile") but I am not sure what value it really gives!
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
www.stfx.ca/people/bliengme
remove caps from email

"JHL" wrote in message
...
Hello,
I have two questions. What is the limit on the number of sheets in a
Excel
file? How can I count the number of sheets in a large worksheet?

Thanks,
JHL




Gary''s Student

Count number of sheets
 
On my computer, about 5447 sheets.

This UDF give the number of sheets:

Function SheetCount() As Integer
Application.Volatile
SheetCount = Sheets.Count
End Function

--
Gary''s Student - gsnu200742


"JHL" wrote:

Hello,
I have two questions. What is the limit on the number of sheets in a Excel
file? How can I count the number of sheets in a large worksheet?

Thanks,
JHL


JHL

Count number of sheets
 
Thank you Gary and Bernard

"Gary''s Student" wrote:

On my computer, about 5447 sheets.

This UDF give the number of sheets:

Function SheetCount() As Integer
Application.Volatile
SheetCount = Sheets.Count
End Function

--
Gary''s Student - gsnu200742


"JHL" wrote:

Hello,
I have two questions. What is the limit on the number of sheets in a Excel
file? How can I count the number of sheets in a large worksheet?

Thanks,
JHL



All times are GMT +1. The time now is 12:03 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com