View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jim Cone Jim Cone is offline
external usenet poster
 
Posts: 3,290
Default Macro to delete rows with font strikeouts


Keep in mind that Strikethrough can return Null for partially struck thru text.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware



"Steve"
wrote in message
I need to create a macro that will scan column A for any cells that contains
text with stikeouts and delete that entire row from the worksheet. My poor
example records manual keystokes but does not function.

Sub DeleteStikeouts()
'
Range("A1:A25").Select
With Application.FindFormat.Font
.Strikethrough = True
.Superscript = False
.Subscript = False
End With
Cells.Find(What:="", After:=ActiveCell, LookIn:=xlFormulas, LookAt:= _
xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext,
MatchCase:=False _
, SearchFormat:=True).Activate
Rows("3:3").Select
Selection.Delete Shift:=xlUp
Range("A3").Select
Cells.FindNext(After:=ActiveCell).Activate
End Sub

Steve