Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Variable containing code

  • To: mathgroup at
  • Subject: [mg75002] Re: [mg74937] Variable containing code
  • From: Carl Woll <carlw at>
  • Date: Fri, 13 Apr 2007 02:18:21 -0400 (EDT)
  • References: <>

dh wrote:

>how can one get at the value of a variable if this value is executable 
>code? E.g. consider variable t1:= Print["Hello"]. How can I set the 
>value of a second variable t2 to the value of t1 without executing the code?
Try OwnValues[t1]

Carl Woll
Wolfram Research

  • Prev by Date: Frameticks Orientation
  • Next by Date: Re: Solving periodic functions
  • Previous by thread: Re: Variable containing code
  • Next by thread: RE: Variable containing code