Réponse acceptée !
f0xy merci 1000 fois le code marche tres bien j'ai rechercher et j'ai trouver un poste ou tu donner un exemple

pour sa a qui sa interesserais avec la recherche en direct dans le richedit
function GetStrPart(const Str, Delimiter: String; const Index: cardinal = 1): String;
var I,P1,P2 : integer;
begin
Result := '';
if (posex(Delimiter,Str[1]) = 1) and (Index <= 1) then exit;
P1 := 1;
for I := 1 to Index-1 do begin
P1 := posex(Delimiter, Str, P1);
if P1 = 0 then exit
else P1 := P1 + length(Delimiter);
end;
P2 := posex(Delimiter, Str, P1);
if P2 = 0 then P2 := length(Str) + 1;
Result := copy(Str, P1, P2 - P1);
end;
procedure TForm2.Button4Click(Sender: TObject);
begin
edit8.Text:=GetStrPart(richedit1.text, 'jjj', 2); //recherche dans le richedit tout se qui commence par jjj et renvoie le resultat dans un Tedit,il recupere se qu'il y a entre jjj

end;
merci encore..