Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

asp equivalent of php variable variables

Status
Not open for further replies.

insania

Technical User
Feb 11, 2004
53
IE
I want to do the same thing as this:

$$variable = $value

but in asp. If the value of $variable was Company then a new variable called Company would be created with the value $value. I cannot find anything that would let me do this in asp. Any help would be appreciated

Thanks
 
Try using execute. A bit clumsy. Something like
Code:
dim bbb, indir
bbb = "bbbbb"
wscript.echo "In the beginning"
wscript.echo "bbb = " & bbb
indir = "bbb"
indir = indir & "= ""xxxxx"""
execute indir
wscript.echo "Afterwords"
wscript.echo "bbb = " & bbb
 
Or to emulate more closely op's question.
[tt]
bbb = "bbbbb"
indir = bbb
indir = indir & "= ""xxxxx"""
execute indir
'or in certain context you may need
'executeglobal indir
response.write "bbbbb = " & bbbbb
[/tt]
 
Thanks guys, Ive decided to try and use multidimensional arrays instead, give me a challenge...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top