Guna13
Board Regular
- Joined
- Nov 22, 2019
- Messages
- 70
- Office Version
- 365
- Platform
- Windows
Hi Team,
In a specific sheet I have over 10000 records, and I need to delete "Blank" data in the "B" column, then delete entire rows the same way I delete "0" values.
Can you suggest any other method or VBA code to delete fast for this code? It takes a little bit of time to delete.
In a specific sheet I have over 10000 records, and I need to delete "Blank" data in the "B" column, then delete entire rows the same way I delete "0" values.
Can you suggest any other method or VBA code to delete fast for this code? It takes a little bit of time to delete.
VBA Code:
Trg.Columns("B").SpecialCells(xlCellTypeBlanks).EntireRow.Delete
Trg.AutoFilterMode = False
Trg.Range("A1:B1000").AutoFilter Field:=2, Criteria1:="0"
'2. Delete Rows
Trg.Range("B2:B1000").SpecialCells(xlCellTypeVisible).Delete
'3. Clear Filter
On Error Resume Next
Trg.AutoFilterMode = False
On Error GoTo 0