House of Fusion
Search over 2,500 ColdFusion resources here
  
Home of the ColdFusion Community

Mailing Lists
Home /  Groups /  ColdFusion Talk (CF-Talk)

Bind to a CFINPUT from a CFGRID

  << Previous Post |  RSS |  Sort Oldest First |  Sort Latest First |  Subscribe to this Group Next >> 
Top  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Chad Baloga
07/29/2010 01:00 PM

I can't seem to figure out how to bind a selected column value in a CFGRID to a text box later on the page. Any ideas?  Thanks

Top  |   Parent  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Ria Ragam
07/30/2010 01:04 AM

gridExample.cfm <cfquery     name="GetParks" datasource="cfdocexamples"     cachedwithin="#CreateTimeSpan(0, 6, 0, 0)#">       SELECT PARKNAME, REGION, STATE       FROM Parks     Where REGION = 'Southeast Region'       ORDER BY ParkName, State </cfquery> <cfform name="GridForm" action=""> <cfgrid name="Brand_Grid" selectmode="row" selectonLoad="no" BindOnLoad="no" query="GetParks" format='html' appendKey ="yes" > <cfgridcolumn name="PARKNAME" header="PARKNAME" headeralign="center" headerbold="Yes"> <cfgridcolumn name="REGION" header="REGION" headeralign="center" headerbold="Yes"> </cfgrid> </cfform> <cfdiv id="id_DivEditeSiteDetail" bind="url:gridOutput.cfm?PARKNAME={GridForm:Brand_Grid.PARKNAME}"></cfdiv> gridOutput.cfm <h3>Echoing main page input:</h3> <cfoutput>     <cfif isdefined("url.PARKNAME") AND url.PARKNAME NEQ "">   <cfoutput>   <table>     <tr>     <td>Park Name:</td>     <td><input value="#url.PARKNAME#" name="ParkName" type="Text"></td></tr>   </table>         </cfoutput>     <cfelse>         No input     </cfif> </cfoutput> > I can't seem to figure out how to bind a selected column value in a > CFGRID to a text box later on the page. Any ideas?  Thanks

Top  |   Parent  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Michael Grant
08/04/2010 07:44 PM

As an aside: I see this time and time again and just don't get it. If you're going to bother to test that url.Parkname exists and isn't a zero length string then why aren't you trimming it when you check? ----- Excess quoted text cut - see Original Post for more -----


<< Previous Thread Today's Threads Next Thread >>

Search cf-talk

September 05, 2010

<<   <   Today   >   >>
Su Mo Tu We Th Fr Sa
       1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30