This is my macro and I need some help, it keeps showing me an error i provably have the macro for the password in the wrong place because with out it it works fine......
Thanks in advance for the tips in the unprotect and the protect stuff...
Thanks
Option Explicit
Private Sub CommandButton1_Click()
ActiveWorkbook.Unprotect Password:="cvz"
Dim x As Range
Dim y As Range
Set y = Range("A7:A371")
Application.ScreenUpdating = False
For Each x In y
If x.Value = "" Then
x.EntireRow.Hidden = True
End If
Next x
Application.ScreenUpdating = True
End Sub
Private Sub CommandButton2_Click()
Cells.EntireRow.Hidden = False
ActiveWorkbook.Protect Password:="cvz"
End Sub
Bookmarks