Sub TranslateCode() Dim c As Range Dim intT, intS, intB As Integer Dim strCurrentRange As String strCurrentRange = Selection.CurrentRegion.Address For Each c In Selection.CurrentRegion 'Find the string position where each substring begins. intT = InStr(c.Value, "T") intS = InStr(c.Value, "S") intB = InStr(c.Value, "B") 'Write the substrings to cells 1, 2, and 3 to the right. 'This routine leaves out the code letter at the start of the substrings. 'Put a single quote in front of the following three lines to disable them. c.Offset(0, 1).Value = Mid(c.Value, 2, intS - 2) c.Offset(0, 2).Value = Mid(c.Value, intS + 1, intB - intS - 1) c.Offset(0, 3).Value = Mid(c.Value, intB + 1) 'These code lines include the code letter at the start of the substrings. 'Remove the single quote from in front of these lines to use them. 'c.Offset(0, 1).Value = Mid(c.Value, 1, intS - 2) 'c.Offset(0, 2).Value = Mid(c.Value, intS, intB - intS - 1) 'c.Offset(0, 3).Value = Mid(c.Value, intB) Next c End Sub