View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Would an Add-in work?

Rob,

This would be okay for an addin.

This code will unprotect and unhide the sheets.

Sub UnhideSheets()
Dim sh As Worksheet
ActiveWorkbook.Unprotect password:="Bob"
For Each sh In ActiveWorkbook.Worksheets
If sh.Visible = xlVeryHidden Then
sh.Visible = True
End If
Next sh
End Sub

Do you want to create a toolbar from the addin as well?

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Rob" wrote in message
...
Excel 2000

I have a number of users that use a predefined spreadsheet to enter weekly
data, this data is then used in hidden worksheets in the file.

The spreadsheet is then emailed to an administration office where they
manually unprotect the worksheet which is password protected (same

password
for all files), they then ALT F11 (VB window) to change the sheets

property
from VeryHidden to Visible.

What I was wondering is, whether this could be automated whereby the admin
office have an Add-in and simply click on a menu item. I've tried without
success to create a menu in a file and then to run vba code to unprotect

and
show the hidden sheets. One issue I can't get my head around is that the
admin office don't save the files they receive to their hard drives, they
simple open the file from their email (lotus notes) which gives the file a
name ~nnnnnnn.

If anyone has some sample code that will set me on the way I would be most
grateful.

Thanks, Rob