View Single Post
  #12   Report Post  
Posted to microsoft.public.excel.programming
prkhan56[_2_] prkhan56[_2_] is offline
external usenet poster
 
Posts: 24
Default Delete Rows as per Text, Font Color, Font Type, Time Format

On Oct 25, 9:22*pm, " wrote:
Let's try this then - with James' permission.

Sub RowKiller()
Dim boo As Boolean, EndOfB As Long, rKill As Range
Dim i As Long
Set rKill = Nothing
EndOfB = Cells(Rows.Count, "B").End(xlUp).Row
For i = 1 To EndOfB
* * With Cells(i, "B")
* * boo = (InStr(1, .Text, ":")) Or (.Value = "ABCD") Or (.Font.Name =
"Arial" And .Font.ColorIndex = 1)
* * If boo Then
* * * * If rKill Is Nothing Then
* * * * * * Set rKill = Cells(i, "B")
* * * * Else
* * * * * * Set rKill = Union(rKill, Cells(i, "B"))
* * * * End If
* * End If
* * End With
Next
If rKill Is Nothing Then
Else
* * rKill.EntireRow.Delete
End If
End Sub

Also please visit *http://www.j-walk.com/ss/excel/tips/tip62.htmfor
checking data types.
Rgds


Hello there,
Thanks a lot ... works great!
You guys are a great great help to us.
Also a big thanks to James

Regards
Rashid