Really thank you for the welcome, the Lazarus community is top notch.
I just tested on Gambas, I get what I want but it looks to me less goods and Pascal lazarus ... A matter of taste I guess.
In fact to explain myself, I try to get the result of a command in a TMemo, when I do:
procedure TForm1.Button1Click(Sender: TObject);
begin
Process1.CommandLine:= 'sh -c "cat /proc/cpuinfo | grep model | cut -c14-"';
Process1.Execute;
Memo1.Lines.LoadFromStream(Process1.Output);
Memo1.Lines.EndUpdate;
Process1.free
end;
It works as I want, even if it tells me
Warning: Symbol "CommandLine" is deprecated
I really do not see how. Maybe I attack too complicated to start Delphi I used correctly but there are more than 15 years ago, and here I am a little lost.
Thank you anyway!
////////////////////////////////////////////////////////////
Vraiment merci pour l'accueil, la communauté Lazarus est vraiment top.
Je viens de tester sur Gambas, j'obtiens ce que je veux mais celui-ci m'a l'air moins biens que lazarus et Pascal... Une question de goût j'imagine.
En fait pour m'expliquer, j'essaye d'obtenir le résultat d'une commande dans un Tmemo, quand je fais :
procedure TForm1.Button1Click(Sender: TObject);
begin
Process1.CommandLine:= 'sh -c "cat /proc/cpuinfo | grep model | cut -c14-"';
Process1.Execute;
Memo1.Lines.LoadFromStream(Process1.Output);
Memo1.Lines.EndUpdate;
Process1.free
end;
Ca fonctionne comme je veux, même si cela m'indique
Warning: Symbol "CommandLine" is deprecated
Je ne vois vraiment pas comment faire. Peut être que je m'attaque à trop compliqué pour commencer J'utilisais Delphi correctement mais il y a plus de 15 ans de cela, et là je suis un peu perdu.
Merci en tout cas ![/size][/font]