Hello!
I would like to find out the size of all the excel worksheets in a workbook. Someone posted this code as a solution:
When I run this, I get this error.

What to do?
Thanks
---------------------------------
>>> use code - tags <<<
I would like to find out the size of all the excel worksheets in a workbook. Someone posted this code as a solution:
When I run this, I get this error.

What to do?
Thanks
---------------------------------
>>> use code - tags <<<
Code:
Sub ParseSheets()
Dim ws As Worksheet
Dim fPath As String
'Where to save sheets
fPath = ThisWorkbook.Path
Application.ScreenUpdating = False
For Each ws In ThisWorkbook.Worksheets
ws.Copy
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs fPath & "\COMPARE_" & ws.Name & ".xlsm"
Application.DisplayAlerts = True
ActiveWorkbook.Close
Next ws
Application.ScreenUpdating = True
MsgBox "Check out the COMPARE files in folder:" & vbNewLine & fPath
End Sub
Last edited by a moderator: