-
Definitely possible.
Save the macro in Personal.xls and it will run on the active woirkbook.
To run it on two sheets you need to loop
[VBA]
Sub RemoveBlanksTwo()
Dim Rng As Range
Dim MyCell
Dim i as Long
For i = 1 To 2
Set Rng = Sheets(i).Range("C9:C119")
With Rng
Set c = .Find(0, LookIn:=xlValues)
If Not c Is Nothing Then
Do
c.ClearContents
Set c = .FindNext(c)
Loop While Not c Is Nothing
End If
Rng.SpecialCells(xlCellTypeBlanks).EntireRow.Delete
End With
Next
End Sub
[/VBA]
MVP (Excel 2008-2010)
Post a workbook with sample data and layout if you want a quicker solution.
To help indent your macros try Smart Indent
Please remember to mark threads 'Solved'
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules