[fpc-pascal] TProcess vs RunProcess()
Marco van de Voort
marcov at stack.nl
Fri Jan 27 18:43:58 CET 2017
In our previous episode, Graeme Geldenhuys said:
> > pause it, write to stdin, read from stdout.
> >
> > These things cannot be done with RunProcess.
> > That's one-shot and wait till it exits.
>
> Another difference.... simply so others might learn from this discussion
> (like I did).
> If you have a huge list of parameters, RunProcess() - at least under
> Windows - will most likely hit a 260 character limit, and then fail to
> actually execute. I don't actually know where that 260 limit originates
> from (Windows API, Command Prompt, FPC etc).
Which runprocess are you talking about? I know a process.runcommand and a
sysutils.executeprocess, but not a runprocess.
> Whereas if you use TProcess and the Parameters (TStrings) property, you
> don't have such a limitation.
>
> This was what I experienced.
if you are talking about executeprocess, test again with trunk.
More information about the fpc-pascal
mailing list