How can I count number of sheets present in a workbook?

B

Bob Phillips

in the immediate window in the VBIDE

?Activeworkbook.Sheets.Count

if you just want the worksheets


?Activeworkbook.Worksheets.Count

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
Top