Solved

hide all sheets

Posted on 2011-02-23
3
288 Views
Last Modified: 2012-05-11
Hi,

Im trying to hide all sheets and its not quite working

Dim objSht
For Each objSht In ActiveWorkbook.Sheets
      objSht.Hidden = xlSheetHidden
   Next objSht
   
Can anyone amend?

Thanks
Seamus
0
Comment
Question by:Seamus2626
3 Comments
 
LVL 47

Expert Comment

by:Wayne Taylor (webtubbs)
Comment Utility
You can't hide *all* sheets, as there must always be one visible at any one time.
0
 
LVL 8

Accepted Solution

by:
pdd1lan earned 500 total points
Comment Utility
you can hide sheets, but you need to leave one open.

Dim objSht
For Each objSht In ActiveWorkbook.Sheets
    If objSht.Name <> "Sheet3" Then
   
      objSht.Visible = xlSheetVeryHidden
    End If

   Next objSht
0
 

Author Closing Comment

by:Seamus2626
Comment Utility
Thats what i need, thanks
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Drop Down List with Unique/Distinct Values (enhancing the Combo-Box with a few steps and a little code) David miller (dlmille) Intro Have you ever created a data validation list from a database field or spreadsheet column (e.g., Zip Codes or Co…
Introduction This Article is a follow-up to my Mappit! Addin Article (http://www.experts-exchange.com/A_2613.html), it was inspired by an email posting I made to EUSPRIG (http://www.eusprig.org/index.htm), I will briefly cover: 1) An overvie…
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now