J
Jerett
Again I have hit a minor problem.
Have a macro that autofilters a range on a worksheet to >0
I have an active x control at the bottom of the workbook
that calls the Macro.
The problem is that I need to protect the workbook. I
have unlocked all of the cells and controls that I am
going to allow the user to change. I have even unlocked
the entire column that the macro uses to filter the
sheet. (I will hide this column before protecting the
sheet)
Unprotected the macro works fine. After protecting the
macro I get a runtime error 1004.
Worksheets("Front").Activate
Cells.Select
Selection.PageBreak = xlNone
Range("F28:F332").Select
Range("F28").Activate
Selection.AutoFilter Field:=1, Criteria1:=">0",
Operator:=xlAnd
ActiveWindow.SelectedSheets.PrintPreview
Have a macro that autofilters a range on a worksheet to >0
I have an active x control at the bottom of the workbook
that calls the Macro.
The problem is that I need to protect the workbook. I
have unlocked all of the cells and controls that I am
going to allow the user to change. I have even unlocked
the entire column that the macro uses to filter the
sheet. (I will hide this column before protecting the
sheet)
Unprotected the macro works fine. After protecting the
macro I get a runtime error 1004.
Worksheets("Front").Activate
Cells.Select
Selection.PageBreak = xlNone
Range("F28:F332").Select
Range("F28").Activate
Selection.AutoFilter Field:=1, Criteria1:=">0",
Operator:=xlAnd
ActiveWindow.SelectedSheets.PrintPreview