[fpc-pascal] TProcess vs RunProcess()
noreply at z505.com
Sun Jan 29 07:14:43 CET 2017
On Thu, January 26, 2017 7:28 am, Michael Van Canneyt wrote:
> On Thu, 26 Jan 2017, Graeme Geldenhuys wrote:
>> Whats the differences or pros and cons between using TProcess vs
> TProcess gives you full access to the process. You can kill it,
> pause it, write to stdin, read from stdout.
> These things cannot be done with RunProcess.
> That's one-shot and wait till it exits.
Similar to FpSystem() and ExecuteProcess, and then there is AssignStream
but assignstream/fpsystem unix only
I like fpsystem because it does not require absolute paths to commands,
too bad fpsystem not available on Windows.
All the above is used in webcmd (part of powtils) and also fpcRun ;-)
But I may try RunProcess/TProcess soon!
More information about the fpc-pascal