I have a macro that does what I want it to do (replace a series of one-letter codes with full words), but I need it to run on just one column. How do I modify it to do that? I would like it to run on column L (except for the first two rows, if possible).
Sub Change_Status_Format()
Dim sht As Worksheet
Dim fndList As Variant
Dim rplcList As Variant
Dim x As Long
fndList = Array("d", "c", "m", "w", "s","div")
rplcList = Array("div", "child", "married", "widowed", "single", "divorced")
'Loop through each item in Array lists
For x = LBound(fndList) To UBound(fndList)
'Loop through each worksheet in ActiveWorkbook
For Each sht In ActiveWorkbook.Worksheets
sht.Cells.Replace What:=fndList(x), Replacement:=rplcList(x), _
LookAt:=xlPart, SearchOrder:=xlByRows, MatchCase:=False, _
SearchFormat:=False, ReplaceFormat:=False
Next sht
Next x
End Sub
Bookmarks