View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default find text in cell and replace it with part of the text in that ce.

Hi jules:

Select the cells you want to clean and run:

Sub reward()
Dim s As String
s = "Rewardsmax_dining_729x90_BUSFIN"
For Each r In Selection
If InStr(r.Value, s) < 0 Then
r.Value = s
End If
Next
End Sub

--
Gary''s Student - gsnu200718