Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: executing commands on exit


From   Nick Cox <njcoxstata@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: executing commands on exit
Date   Tue, 13 Sep 2011 14:24:10 +0100

I think you need to ensure that your last command is

di "$S_DATE $S_TIME"

Alternatively, your last command could just close the log. It's not
really clear why you aren't doing that.

Nick

On Tue, Sep 13, 2011 at 2:15 PM, A. Berâ <abdullahbera@gmail.com> wrote:
> Yes but I also want to have closing date and time as we would see if
> we closed the log file manually.
>
> a.b.
>
> On Tue, Sep 13, 2011 at 4:01 PM, Maarten Buis <maartenlbuis@gmail.com> wrote:
>> On Tue, Sep 13, 2011 at 2:54 PM, A. Berâ <abdullahbera@gmail.com> wrote:
>>>    How can I make Stata open a log file (with a name say temp)
>>> automatically when it starts and close it automatically when I exit
>>> Stata?
>>>
>>> I know I can put
>>>
>>> .log using temp.log, name(temp)
>>>
>>> in profile.do, but I don't know how to close it automatically when I
>>> exit Stata.
>>
>> If a log file is open when you close Stata, than closing Stata will
>> also close that log file.
>>

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index