470,815 Members | 1,318 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,815 developers. It's quick & easy.

Reverse of $$

$$ allows on to put a variable name in another variable and use it. I
would like a function, usable only in UDFs, that would return the actual
variable name associated with a function argument. This is,
approximately, the inverse of $$. One can achieve this by requiring the
user to to send all arguments as strings and using $$ throughout, but
that puts an undue burden on the function user.
Apr 13 '06 #1
3 1035
Bob Stearns wrote:
$$ allows on to put a variable name in another variable and use it. I
would like a function, usable only in UDFs, that would return the actual
variable name associated with a function argument. This is,
approximately, the inverse of $$.


Not possible. Think about it - what if the arguments aren't named
variables, e.g.:

foo(6, 6*$val, getNumber());

--
Oli

Apr 13 '06 #2

Bob Stearns wrote:
$$ allows on to put a variable name in another variable and use it. I
would like a function, usable only in UDFs, that would return the actual
variable name associated with a function argument. This is,
approximately, the inverse of $$. One can achieve this by requiring the
user to to send all arguments as strings and using $$ throughout, but
that puts an undue burden on the function user.


But how do you refer to the variable when you don't know its name?

Apr 13 '06 #3
Bob Stearns wrote:
$$ allows on to put a variable name in another variable and use it. I
would like a function, usable only in UDFs, that would return the actual
variable name associated with a function argument. This is,
approximately, the inverse of $$.


Not possible. Think about it - what if the arguments aren't named
variables, e.g.:

foo(6, 6*$val, getNumber());

--
Oli

Apr 13 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

35 posts views Thread by Raymond Hettinger | last post: by
59 posts views Thread by Raymond Hettinger | last post: by
3 posts views Thread by engsolnom | last post: by
8 posts views Thread by Jim Langston | last post: by
14 posts views Thread by ford_desperado | last post: by
20 posts views Thread by mike7411 | last post: by
15 posts views Thread by rajash | last post: by
reply views Thread by mihailmihai484 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.