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

st: RE: locals and programs

From   "Martin Weiss" <>
To   <>
Subject   st: RE: locals and programs
Date   Sat, 8 Aug 2009 14:23:29 +0200


" Local macros exist solely within the program or do-file in
which they are defined." As devertised a couple of times in recent history
of the list. See [P], p. 193.

In any event, the assignment - local aa = TTT- would not do any good for
you. If it was supposed to work, it would have to be - local aa = `TTT'- so
that the content of TTT, not the string "TTT" get stored...


-----Original Message-----
[] On Behalf Of Paulo Regis
Sent: Samstag, 8. August 2009 14:09
Subject: st: locals and programs

Hi all,

I have which should be a simple question but still I do not manage to
solve it. I simplified the problem as much as possible. If you run the
following code and use the command -TT, you get an error message.

capture program drop aaa
program define aaa
local aa = TTT
display `aa'

capture program drop TT
program define TT
local TTT = 5

How can I use the local "TTT" in the programme "aaa". Solving this
issue may save me much time since the code is quite long


*   For searches and help try:

*   For searches and help try:

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