Frangy, ta solution me convient très bien mais le seul problème c'est lorsqu'il y a un zéro au sein de la chaine de caractère, il ne le prend pas en compte..
TIX72553 72553
FI72223 72223
LIX62908 6298
FIX72603 7263
FIX62924 62924
Voici mon code:
Application.ScreenUpdating = False
Set Ws = ActiveWorkbook.Worksheets("Plant_Hierarchy")
DerLig = Ws.Range("D" & Rows.Count).End(xlUp).Row
For Each C In Ws.Range("D2:D" & DerLig)
Cptr = 0
For i = Len(C) To 1 Step -1
If IsNumeric(Mid(C, i, 1)) Then
Cptr = Cptr + 1
If Cptr < 6 Then C.Offset(0, 1) = Mid(C, i, 1) & C.Offset(0, 1)
End If
Next i
'If Len(C.Offset(0, 1)) < 5 Then
'C.Offset(0, 1).Delete
'End If
Application.DisplayAlerts = False
Next C
With Ws.Sort
.SortFields.Clear
.SortFields.Add Key:=Ws.Range("E2:E" & DerLig), _
SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
.SetRange Ws.Range("D2:E" & DerLig)
.Apply
End With
'Ws.Range("E1:E" & DerLig).ClearContents
Set Ws = Nothing
Vois tu un truc à rajouter?