Bonjour
J'ai déjà écrit ça pour qq qui demandais la meme chose :
Function RtElement (Champ as String, Separateur as Boolean, Numero as int) as string
Dim i, NoElt as int
NoElt = 1
if Instr(1,Champ,Separateur) = 0 then
RtElement = Champ
exit function
end if
For i = 1 To Len(champ)
If Mid(champ, i, 1) = Separateur Then
NoElt = NoElt + 1
Else
If NoElt = Numero Then
RtElement = RtElement & Mid(champ, i, 1)
End If
End If
Next
Cette fonction retourne l'élément Numero d'une chaine Champ avec un Séparateur.
Dans ton cas pour retourner l'addresse (séparateur est la virgule et le numero est 19) :
str = "172.16.6.58, anonymous, -, N, 5/26/03, 0:00:03, 1, -, -, 172.16.1.35, -, 3128, -, 95, 510, http, -, -, http://chat0.tchatche.com/chat1/images/region.gif, -, NotModified, 0, 0"
addresse = RtElement(str,",",19)
a+
,.~*`'^~.(^. :question) .^),.~^'`*~.