Worksheets hidden

  • Thread starter Thread starter Jean-Pierre Hermans
  • Start date Start date
J

Jean-Pierre Hermans

Hello,

When i put in workbook_open the following code :

For Each ws In Worksheets
ws.Visible = xlSheetHidden
Next

I get an error code: runtime error 1004 unable to set the visible property
of the worksheet class

Does anyone know how to solve that ?

Thnx.
 
Not an expert, but;
I think there must be at least one visible WS in a Workbook.
 
At least one worksheet needs to be visible.

for i = 2 to worksheets.count
worksheets(i).Visible = xlSheetHidden
Next
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top