Thread
:
Remove a row if data is bold
View Single Post
#
2
Posted to microsoft.public.excel.programming
Don Guillett
external usenet poster
Posts: 10,124
Remove a row if data is bold
Try
Sub deleteboldrows()
mc="a"
For i = 2 To cells(rows.count,mc).end(xlup).row
If Cells(i, mc).Font.Bold Then Rows(i).Delete 'MsgBox i
Next i
other code here
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software
"JR" wrote in message
...
I have a report that comes from another source. It repeats the header
every so many lines and that can vary. The header is the only bold
thing in the spreadsheet. Is there a way to parse thru the
spreadsheet and any row that it finds something in the A column is
bold, delete the whole row? Also there are funny characters in the
spreadsheet at the end and I have the below macro running to strip it
all out. Not sure if a macro could be integrated into this so there
is only one?
Sub fixme()
Selection.Replace What:=Chr(160), Replacement:="", LookAt:=xlPart,
_
SearchOrder:=xlByRows, MatchCase:=False
End Sub
Any ideas would be appreciated.
Thanks.
JR
Reply With Quote
Don Guillett
View Public Profile
Find all posts by Don Guillett