O
ogopogo5
I wrote this code and I wanted it to find and delete any single "0"
(zero). However it is deleting any numbers with zeros, I.E. 10, 100,
150, 10,275 etc. Is there a way to write it so it will find a single
"0"? The following is the code I wrote.
Sub FindZero
For x = 1 To 6
Dim rngFound As Range
Set rngFound = Cells.Find(What:="0", After:=ActiveCell, _
LookIn:=xlFormulas, LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, MatchCase:=False,
SearchFormat:=False)
If Not rngFound Is Nothing Then
rngFound.Select
Selection.Clear
End If
Next x
End Sub
Ogopogo5
*** Sent via Developersdex http://www.developersdex.com ***
(zero). However it is deleting any numbers with zeros, I.E. 10, 100,
150, 10,275 etc. Is there a way to write it so it will find a single
"0"? The following is the code I wrote.
Sub FindZero
For x = 1 To 6
Dim rngFound As Range
Set rngFound = Cells.Find(What:="0", After:=ActiveCell, _
LookIn:=xlFormulas, LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, MatchCase:=False,
SearchFormat:=False)
If Not rngFound Is Nothing Then
rngFound.Select
Selection.Clear
End If
Next x
End Sub
Ogopogo5
*** Sent via Developersdex http://www.developersdex.com ***