I have a simple macro I'm having difficulty with. I'm trying to complete a copy and replace using text from a row. For example, in the code below, the replacement is "BC", which is fine if that's the heading, but if the heading changes to "BD" I need the replacement to be "BD", but I can only get the code to keep the same replacement text of "BC". What can I do so the paste in the replacement field what I copied, not "BC"?
Range("B6").Select
Selection.End(xlToRight).Select
ActiveCell.Offset(-3, 0).Range("A1").Select
Selection.Copy
Selection.End(xlDown).Select
Range(Selection, Selection.End(xlDown)).Select
ActiveCell.Range("A1:A245").Select
Selection.Replace What:="A", Replacement:="BC", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=True, SearchFormat:=False, _
ReplaceFormat:=False
Range("B6").Select
Selection.End(xlToRight).Select
ActiveCell.Offset(-3, 0).Range("A1").Select
Selection.Copy
Selection.End(xlDown).Select
Range(Selection, Selection.End(xlDown)).Select
ActiveCell.Range("A1:A245").Select
Selection.Replace What:="A", Replacement:="BC", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=True, SearchFormat:=False, _
ReplaceFormat:=False