Re: Command-line does work when scheduled
- From: Jim <jscrerar@xxxxxxxxxxxxxx>
- Date: Sat, 29 Sep 2007 18:04:06 -0700
On Sep 29, 6:56 pm, "Gabriel Genellina" <gagsl-...@xxxxxxxxxxxx>
wrote:
En Sat, 29 Sep 2007 19:17:49 -0300, Jim <jscre...@xxxxxxxxxxxxxx> escribi?:
On Sep 29, 3:19 pm, "Gabriel Genellina" <gagsl-...@xxxxxxxxxxxx>
wrote:
En Sat, 29 Sep 2007 17:34:34 -0300, Jim <jscre...@xxxxxxxxxxxxxx>
escribi?:
I want to schedule a Python program that reads the command line for
input. However, when adding an argument to the command line Python
will not pick it up when using Windows scheduled tasks.
How do I get it to work?
Do you write the command line when defining the task? Using double
quotes
around arguments with spaces?
It works fine for me.
I ran the following on the Scheduled Tasks:
"J:\Jim Crerar\MyPython\Zero_OE_Counter\Zero_OE_Counter.py" n
"J:\Jim Crerar\MyPython\Zero_OE_Counter\Zero_OE_Counter.py n"
"J:\Jim Crerar\MyPython\Zero_OE_Counter\Zero_OE_Counter.py" "n"
None of them work.
However, no problem with running from *.bat file or directly from
shortcut on my Desktop.
Try prepending the Python executable:
C:\Python25\Python.exe "J:\Jim
Crerar\MyPython\Zero_OE_Counter\Zero_OE_Counter.py" n
If it works this way, maybe the .py file extension is not correctly
registered.
--
Gabriel Genellina- Hide quoted text -
- Show quoted text -
Yes, it works this way.
How do I register the .py extension correctly?
Thanks,
Jim
.
- Follow-Ups:
- Re: Command-line does work when scheduled
- From: Gabriel Genellina
- Re: Command-line does work when scheduled
- References:
- Command-line does work when scheduled
- From: Jim
- Re: Command-line does work when scheduled
- From: Gabriel Genellina
- Re: Command-line does work when scheduled
- From: Jim
- Re: Command-line does work when scheduled
- From: Gabriel Genellina
- Command-line does work when scheduled
- Prev by Date: Re: Command-line does work when scheduled
- Next by Date: Optparse and help formatting?
- Previous by thread: Re: Command-line does work when scheduled
- Next by thread: Re: Command-line does work when scheduled
- Index(es):
Relevant Pages
|