Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

RE: st: Auto-run program on the hour, every hour


From   "Rajesh Tharyan" <[email protected]>
To   <[email protected]>
Subject   RE: st: Auto-run program on the hour, every hour
Date   Wed, 11 Jun 2008 07:29:24 +0100

Hi,

Save the file after step1 as somefilename.bat

Cheers
rajesh

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Rajesh Tharyan
Sent: 11 June 2008 07:16
To: [email protected]
Subject: RE: st: Auto-run program on the hour, every hour

Hi,

Try creating a .bat file to call stata and run the do file and then run the
.bat file it with the scheduler. 
It should work. This worked for me..

Steps

1. Open notepad or whatever text editor and enter the following,  ammended
suitably to fit your setup

Start/w C:\Progra~1\Stata10\wsestata.exe  do "C:\paper4\myprogram.do"

2. Then use the windows scheduler in Winxp to run the bat file, which in
turn calls up stata and runs the do file

Hope this helps
rajesh



-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Dan Weitzenfeld
Sent: 10 June 2008 23:19
To: [email protected]
Subject: Re: st: Auto-run program on the hour, every hour

This is helpful.  My OS is Windows XP.  I'm trying to tinker with the
properties of the scheduled task  to get it to work... right now all
it does is pass the name of the do-file to stata in quotes, and Stata
responds by saying that it's not a valid command.  Does anyone know of
a way around this?

On Sat, Jun 7, 2008 at 7:01 PM, Jeph Herrin <[email protected]> wrote:
>
> I think you want the OS to do this, not Stata. You
> don't say what your OS is, in Linux see -at-, in
> XP use the scheduler (Start->Accessories->System Tools
> -> Scheduled Tasks on my setup, but yours may vary).
>
> I don't know about a Mac, though I assume OS X has a
> command line version of -at-.
>
> hope this helps,
> Jeph
>
>
> Dan Weitzenfeld wrote:
>>
>> Hi All,
>> Is there a way to have a do-file or program run at a given clock-time
>> every day, automatically?
>> I can think of a kluge, whereby the program is infinitely looping, and
>> if c(current_time) fits the desired criteria, the process runs.
>> I'm wondering if there is a more sane way to achieve this result?
>> Thanks in advance,
>> Dan
>> *
>> *   For searches and help try:
>> *   http://www.stata.com/support/faqs/res/findit.html
>> *   http://www.stata.com/support/statalist/faq
>> *   http://www.ats.ucla.edu/stat/stata/
>>
> *
> *   For searches and help try:
> *   http://www.stata.com/support/faqs/res/findit.html
> *   http://www.stata.com/support/statalist/faq
> *   http://www.ats.ucla.edu/stat/stata/
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index