[Tutor] os.system() with NO_WAIT

János Juhász janos.juhasz at VELUX.com
Mon Aug 7 10:11:06 CEST 2006


Dear Guys,

I have a small script that is running on a terminal server's client 
session.

#######
import os
import time
import glob

def send():
    print 'I am checking %s' % time.ctime()
    if len(glob.glob(r'U:\ediout\DESADV\*.doc')) > 0:
        os.system('vedicom.exe')

if __name__ == '__main__':
    os.chdir(r'U:\vedicom\DESADV\\')
    while 1:
        send()
        time.sleep(30)
#######

As you can see, it is just start a windows program from a folder, when 
there are files in that folder.
My problem comes when the network connection is broken. In that case, this 
program wait a user interaction to push a button.
When the connection come back, it is just waiting to push the button and 
we are missing to send the EDI documents.

Have you got any idea how I can strart this windows GUI program with not 
waiting its return.




Yours sincerely, 
______________________________
János Juhász 
VELUX Magyarország Fertődi Építőkomponens Kft. 
IT Department
Malom Köz 1, H-9431 Fertőd 
Telephone direct:      +36 99 537 939
Telephone office:      +36 99 537 920
Office fax:                +36 99 537 921
Telephone mobile:    +36 30 682 6331
@                             janos.juhasz at VELUX.com
www                        www.VELUX.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20060807/530d068c/attachment.htm 


More information about the Tutor mailing list