Function Battage(ByVal S1 As String, ByVal S2 As String, ByVal S As String) As Boolean
Dim i%
If Not (Len(S1) + Len(S2) = Len(S)) Then Battage = False: Exit Function
If Len(S1) = 0 Then
For i = 0 To Len(S2) - 1
If Not (Mid$(S2, i + 1, 1) = Mid$(S, i + 1, 1)) Then Battage = False: Exit Function
Next i
Battage = True: Exit Function
End If
If Len(S2) = 0 Then
For i = 0 To Len(S1) - 1
If Not (Mid$(S1, i + 1, 1) = Mid$(S, i + 1, 1)) Then Battage = False: Exit Function
Next i
Battage = True: Exit Function
End If
If Mid$(S1, 1, 1) = Mid$(S, 1, 1) Then
If Battage(Right$(S1, Len(S1) - 1), S2, Right$(S, Len(S) - 1)) Then Battage = True: Exit Function
End If
If Mid$(S2, 1, 1) = Mid$(S, 1, 1) Then
If Battage(S1, Right$(S2, Len(S2) - 1), Right$(S, Len(S) - 1)) Then Battage = True: Exit Function
End If
Battage = False
End Function