[BangPypers] Reg : Python Scripting

murugadoss murugadoss2884 at gmail.com
Mon Dec 14 05:34:22 CET 2009


Hello,
   I am new to python scripting. I saw about subprocess module. I need to
send an input to the running src,like

eg: For adding two numbers
       1. image running and waiting for input from user
        2. input 1
       3. input 2

eg:
./add.src
2
3
Can u please give me some more input how to pass there inputs

--
Thanks & Regards
V.Murugadoss


On Wed, Dec 9, 2009 at 8:36 PM, Roshan Mathews <rmathews at gmail.com> wrote:

> On Wed, Dec 9, 2009 at 4:34 PM, murugadoss <murugadoss2884 at gmail.com>
> wrote:
> > But since the thread is waiting for input ( in a while loop ), the
> control
> > is not coming to next line of the script. (ie: to input arguments line).
> >
> > Sample Script:
> > os.system(my program)
> > child.sendline(input arguments)
>
> subprocess: http://docs.python.org/library/subprocess.html
>  _______________________________________________
> BangPypers mailing list
> BangPypers at python.org
> http://mail.python.org/mailman/listinfo/bangpypers
>


More information about the BangPypers mailing list