okay this is what I have:
Private Sub Workbook_Open()
'check for filter, turn on if none exists
With Worksheets("worksheet")
If Not .AutoFilterMode Then
.Range("A2").AutoFilter
End If
.EnableAutoFilter = True
.Protect Password:="password", _
Contents:=True, UserInterfaceOnly:=True
Range("C:C,D,L:L").Selec
Selection.Locked = True
End With
End Sub
Private Sub Workbook_Open()
'check for filter, turn on if none exists
With Worksheets("worksheet")
If Not .AutoFilterMode Then
.Range("A2").AutoFilter
End If
.Range("C:C,D,L:L").Locked = True
.EnableAutoFilter = True
.Protect Password:="password", _
Contents:=True, UserInterfaceOnly:=True
End With
End Sub
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.