Thread: [Solved] Find replace issues!! Help!!
View Single Post
 
Old 07-02-2012, 05:36 PM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Try the following macro:
Code:
Sub UpdateRefs()
Dim StrFnd As String, StrRep As String
StrFnd = InputBox("Please input the string to FIND for the replacement.", "Find/Replace")
If StrFnd = "" Then Exit Sub
StrRep = InputBox("Please input the string with which to REPLACE the Find String.", "Find/Replace")
With Application
  .DisplayAlerts = False
  .ScreenUpdating = False
  .Calculation = xlManual
  .ActiveSheet.Cells.Replace What:=StrFnd, Replacement:=StrRep, LookAt:=xlPart, _
    SearchOrder:=xlByColumns, MatchCase:=False, SearchFormat:=False, ReplaceFormat:=False
  .Calculation = xlAutomatic
  .DisplayAlerts = True
  .ScreenUpdating = True
End With
End Sub
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote