Conditional data binding with cfgrid?
I have the following:
<cfform action="action.cfm" format="flash" method="post">
<cfformgroup type="horizontal">
<cfformgroup type="page" label="Email">
<cfgrid name="email" query="email">
<cfgridcolumn name="question">
</cfgrid>
</cfformgroup>
<cfformgroup type="page" label="Paycheck">
<cfgrid name="paycheck" query="paycheck">
<cfgridcolumn name="question">
</cfgrid>
</cfformgroup>
</cfformgroup>
<cfformgroup type="panel" label="Answer">
<cfformitem type="html" bind="{((email.selectedItem.question == undefined) ? '' : email.selectedItem.answer
(paycheck.selectedItem.question == undefined) ? '' : paycheck.selectedItem.answer)}"></cfformitem>
</cfformgroup>
</cfformgroup>
</cfform>
I presume there is a syntax error in the value of the BIND attribute of the CFFORMITEM tag. In plain-English, I'm essentially trying to say (and I'm simply not experienced enough with ActionScript to know how to do this):
If a row in the cfgrid named, "email" is selected, make the value of the answer column from the email query the value of the CFFORMITEM tag. Otherwise, if there is a row in the cfgrid named, "paycheck" that has been selected, make the value of the answer colum from the paycheck query the value of the CFFORMITEM tag.
TIA
