Hi all,
I have four tabs (2009, 2010, 2011, 2012) with more than 2000 rows with names mixed with characters in parenthesis and codes (lets call them mixed-names) in columns (B1:B2000). In another tab: References, I have a column (D1:D1500) with names (lets call them unique names) which are part of the 'mixed-names'.
Just an example: Mixed names: BbExcelforum(04356), tta56(VBAexcel)&port
Unique Names: Excelforum, VBAexcel (which are recorded in the tab: References, Column D1:D1500).
Is there any way to read the names in column D1:D1500 (if they are part of the mixed names) and replace the mixed names with the unique names?
I have found this code but this only reads manually and I have to specify each time the type of search I want, but with 1500 names..its being quite tough.
Any help? Thanks a lot.Sub ReplaceAll()
Dim Wks As Worksheet
For Each Wks In Worksheets
If Wks.Name <> "Sheet1" Then
Wks.UsedRange.Replace _
What:="TIA", Replacement:="TI/A", _
SearchOrder:=xlByColumns, MatchCase:=True
Wks.UsedRange.Replace _
What:="TI.A", Replacement:="TI/A", _
SearchOrder:=xlByColumns, MatchCase:=True
End If
Next Wks
End Sub
Bookmarks