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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting the value of a dynaminc variable...

Status
Not open for further replies.

rdiller

Programmer
Sep 13, 2000
9
0
0
US
Okay... I really NEED everyones help with this one.

I have to request the values for a list of items, there could be 2 there could be 15... so geneterate the form by using..

<CFFORM NAME=&quot;act_pay&quot; METHOD=POST ACTION=&quot;next_page.cfm&quot;>
<CFOUTPUT QUERY=&quot;audit_info&quot;>
<CFINPUT TYPE=TEXT NAME=&quot;act_pay_#id#&quot;>
</CFOUTPUT>
<INPUT TYPE=SUBMIT>
</CFFORM>

I use the ID so that it will give me unique names for all the fields. But the problem lies when I try to get those values again...

basically what I want it to say is
#form.act_pay_#id## but that doesn't work. Does this make sense what I'm attempting... anyone with info... please help.

Ryan
[sig][/sig]
 
Mind you, I'm not really sure on this one and I have no way of testing it at the moment, but I'd try something like:
Code:
<CFSET Tmp=&quot;Form.act_pay_&quot; & id>
#Evaluate(tmp)#

I'm not sure I've got it exactly right, but it should work using the evaluate function.

Hope this helps,

Brommrrrr [sig][/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top