[solved] TProcess: Parameters.Add leads to empty Commandline lazarus / 31-LCL ---------------------------------------------------------------------- Ocye · 2014-05-12 15:59 Nothing happens when I use the following code. The legacy method works well. Did I miss something? Code: [Select]  with TProcess.Create(nil) do   try //    CommandLine:='ffmpeg -r 2 -i /tmp/img%d.png -r 25 test.mpg'; //works     Executable:='/usr/bin/ffmpeg'; //ffmpek > "executable not found"     Parameters.Add('-r 2');     Parameters.Add('-i '+GetTempDir+'img%d.png');     Parameters.Add('-r 25');     Parameters.Add('test.mpg');     ShowMessage(CommandLine);  //empty     Execute;   finally     Free; //TProcess   end; //no output, no error ---------------------------------------------------------------------- taazz · 2014-05-12 16:53 well commandline is a one way road it gives params and executable to TProcess but it does not reconstruct it self from the existing params you would have known that if you simple took a fast look on the class your self. ---------------------------------------------------------------------- Ocye · 2014-05-12 17:20 Thank you for reply. But actually my question is why Parameters.Add() don't work. I have no clue what happens (nothing) and expected a Commandline generated from Paramaters (of course, it's not imperative). But there is nothing. So what's wrong with the code snippet? ---------------------------------------------------------------------- marcov · 2014-05-12 18:36 Quote from: Ocye on May 12, 2014, 05:59:58 pm     Parameters.Add('-r 2');     Parameters.Add('-i '+GetTempDir+'img%d.png');     Parameters.Add('-r 25'); These are wrong, use one .add add for each item   add('-r')  and add('2'); etc. ---------------------------------------------------------------------- Ocye · 2014-05-12 20:46 Quote from: marcov on May 12, 2014, 08:36:24 pmThese are wrong, use one .add add for each item   add('-r')  and add('2'); etc. I thought a parameter consists of switch plus value, but apparently there is no whitespace allowed. Now it works. Thanks a lot!