Unknown Sheets in WB

Brian.Crawford

Board Regular
Joined
Oct 3, 2007
Messages
136
Excel 2007. Over time (and many [100's] Excel "Is not responding" anymore "the white screen of death") I seemed to have accumulated a few extra WS in my WB. These sheets are not viewable (cannot be UnHidden) and do not have there VeryHidden property set.

What is odd is that these "sheets" do not have the "sheet" icon in project explorer, instead they have the workbook icon.

Also, they are called "sheets" (10 & 16) in project explorer but when clicked on their "type" (ie name) in their properties window is "thisWorkbook" along with the real "thisWorkbook" (that looks and is normal, with code).

There is no code associated with these "things".
Suggestions on their source and how to get rid of them (can't remove or delete them)?

thanks
Brian
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
Code like
Code:
ActiveSheet.Copy
will create a new Workbook with a name like Sheet1. That may be the source of your problem.
 
Upvote 0
That is very possibly what happened...

But how do I get rid of it now.
I can't see them in "Excel" (on sheet tabs) and project explorer won't let me do anything with them either.
 
Upvote 0
I tried "sheets(...).delete" in the immediate window but no luck.
These sheets do not a a name (other than the sheet number [ex Sheet16]) so I clicked on one and tried to rename it and... it ended up renaming the real "thisWorkBook" (tried it twice to be sure).

That is a bit scary?
thoughts anyone

Brian
 
Upvote 0
Do they show up if you do something like this?

Dim ws As Worksheet

For Each ws In Worksheets
Msgbox ws.Name
Next ws
 
Upvote 0
It sounds like they are not worksheet, but workbooks.
Try this, close the workbooks that you like and want.
Open a new workbook, put this macro in that workbook and run it

Code:
Sub ListWorkbooks()
    Dim i as Long
    For i = 1 to Workbooks.Count
        With Workbooks(i)
            ActiveSheet.Cells(i, 1).Value = .Name
            ActiveSheet.Cells(i, 2).Value = .Path
            ActiveSheet.Cells(i, 3).Value = "contains " & .Sheets.Count & " sheets"
        End With
    Next i
End Sub
Then look at the sheet in the new workbook to see what is what. The path will let you know where to do to delete the files.
 
Upvote 0
Not sure I understand, ..these "things" are all in a single project (under one project/WB name an ".xlsm") so not sure how differntiate/select the ones I "like". I just now opened another WB and I see it has some of the same types of things in it? It to has been party to some Excel crashes.
 
Upvote 0

Forum statistics

Threads
1,224,621
Messages
6,179,937
Members
452,949
Latest member
beartooth91

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top