Re: question catching system message
- Posted by jacques deschĂȘnes <desja at globetrotter.?et> Aug 11, 2007
- 480 views
what's wrong this method its simple and effective. You can also do system("dir *.txt > temp.txt 2> error.txt",2) then you have separated files for the command output and command error. j.d. Salix wrote: > > Is there a way to catch the reply of system() under Win32? > The following is incorrect sytax but that's what I mean: > }}} <eucode> > sequence sx > sx=system("dir *.txt",2) > </eucode> {{{ > > Currently the only way I can do it is this > }}} <eucode> > sequence sx > system("dir *.txt > temp.txt",2) > sx=read_file("temp.txt") > </eucode> {{{ > > Any tips? > > Thanks, > > Salix