I need some help figuring out what I am doind wrong here.
The goal:
- Perform Autofilter
- Then, with the rows that are left visible, I wish to insert a row above them
I have tried and tried to no avail:
My code:
[vba]
With Range("A1")
.AutoFilter Field:=1, Criteria1:="=*/01"
.Offset(1, 0).SpecialCells(xlCellTypeVisible).Rows.Insert Shift:=xlDown
End With
[/vba]
So I tried the "Recorder" and got this:
[vba]
Selection.AutoFilter Field:=1, Criteria1:="=**/01*", Operator:=xlAnd
Rows("4:70").Select
Selection.SpecialCells(xlCellTypeVisible).Select
Selection.Insert Shift:=xlDown 'Error occurs here
[/vba]
Right after I recorded this, I exicuted the "Recorded" code, it is errors...
Usising Excel 2003
Any help would be greatly appreciated,
Phil