I think this is what you were looking for. I took out lots of code because I
also do server side validation and if it fails, I color the "failed" info
yada yada yada...
On the for page:
---------------------------
<cfloop query="industry">
<cfif #isdefined("form.indExp#intIndustryID#")#>
<cfset CurrIndValue = evaluate("indExp#intIndustryID#")> <!--- this
gives
us the field value --->
</cfif>
<cfinput type="Text" maxlength="2" value='#currIndValue#'
name='indExp#intIndustryID#' size="2" align="left"> #strIndustry#
</cfloop>
<input type="Hidden" name="listintIndustryID"
value=#ValueList(industry.intIndustryID)#>
---------------------------
On the Processing page:
---------------------------
<!--- Add the Industry Experience info for the candidate --->
<cfloop index="iName" list=#form.listintIndustryID#>
<cfset indName=Evaluate('form.indExp' & iName)>
<cfif #indName# eq "">
What ever you want the code to do here
<cfelse>
<CFQUERY NAME="addCandIndExp" DATASOURCE="#dataSource#">
INSERT INTO tblCandIndExp
(intCandidateIDFK, intIndustryIDFK, intCandIndYrs)
VALUES
<cfoutput>
(#candID#,#iName#,#indName#)
</cfoutput>
</cfquery>
</cfif>
</cfloop>
---------------------------
Hope this is what you were looking for...
If you still can't get it, send me that portion of code and I'll take a
look.
Stephen
-----Original Message-----
From: Max Paperno [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 28, 2001 3:34 AM
To: CF-Talk
Subject: Re: Stumped !
Jim,
If I understand the base of your problem, it's in trying to get the value of
a dynamically-named form field. Right? If so, it's easy...
formFieldValue = Evaluate("form.sameword" & number)
presuming "number" is your incrementing value. Does that do it?
Cheers,
-Max
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists