Statalist


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

Re: st: re: how to link the help file for a command to itsimmediate


From   Michael McCulloch <[email protected]>
To   [email protected]
Subject   Re: st: re: how to link the help file for a command to itsimmediate
Date   Mon, 29 Sep 2008 11:15:30 -0700

Not having ever written an ado file, I apologize for the elementary question. If I run the do-file editor:

program mike, saving(mike.ado)
...
end

and then type "mike", Stata does return the "..." but the program's ado file doesn't end up in ado\personal, even though I first set that as the working directory. How do I save it, and then what Stata manual should I obtain & course should I take to begin to learn ado programming?
Michael







< >
Michael said

I like this approach, and it echoes a thread from last week about
abbreviations. Will those new ado files be saved, or do they need to
be re-invoked for each Stata session? And, if it needs to be
re-invoked, could they all be launched by one do-file such as
"my_abbreviations.do"?


Well, if you save them in PERSONAL, they will be saved. You do not need to invoke ado-files; that's what Stata does when you execute the comamnd they define. Each ado-file defines a command, so no, you cannot put more than one in a file. They must be in their own files for this to work. (It is possible to have

---mike.ado---
program mike
...
end
program george
....
end
program bill
...
end
------------------
but then the george and bill commands are only accessible to program mike, and not elsewhere.

Kit Baum, Boston College Economics and DIW Berlin
http://ideas.repec.org/e/pba1.html
An Introduction to Modern Econometrics Using Stata:
http://www.stata-press.com/books/imeus.html


*
* 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/
*
*   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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index