Hi
this macro should create a string from the code in the selected cells and put that string in the cell to the right of the one with the code:
Sub DelNonCode()
Dim Txt As String, DelCar As Boolean, CCell As Range, x As Long
For Each CCell In Selection.Cells
DelCar = True
Txt = ""
For x = 1 To Len(CCell)
If Mid(CCell, x, 1) = "<" Then DelCar = False
If DelCar = False Then Txt = Txt & Mid(CCell, x, 1)
If Mid(CCell, x, 1) = ">" Then DelCar = True
Next x
CCell.Offset(0, 1) = Txt
Next CCell
End Sub
it could be tweaked into a user-defined formula, if you like
Bookmarks