System(); is able to call a program in PATH. How is it possible to send stdin read from e.g. a text field on a GUI to a command line program such as ftp, sftp ... with their own prompts?
System() waits for a program to quit, but ftp does not without user interaction. It s also not possible to create a batch file since it s read only one time in runtime, on start.
If possible, please write the solution in C for UNIX, if not in any other language.