Skip to main content
Astonished_protector15C3
Participating Frequently
December 9, 2009
Question

Dynamic Check box in Flash Form

  • December 9, 2009
  • 1 reply
  • 433 views

I am struggling with the Dynamic check box in flash form i am not fimilar with the action script.

The check box are generate by a query result and its names generate dynamically eg: subject_1,subject_2,subject_3 etc. How can i get the value from these checkboxes if its checked and also i need to populate the check boxes based on the data from database query in action script.

    This topic has been closed for replies.

    1 reply

    Dileep_NR
    Inspiring
    December 9, 2009

    Hi VKR,

    Please try this,

    <cfform name="frmTest"  format="Flash" action="test.cfm" method="post"  >
    <cfscript>
        qryCountry = queryNew("Country,CountryID");   
          queryAddRow(qryCountry);  
          querySetCell(qryCountry, "Country", "India");  
          querySetCell(qryCountry, "CountryID", "1");  
          queryAddRow(qryCountry);  
          querySetCell(qryCountry, "Country", "England");
           querySetCell(qryCountry, "CountryID", "2");    
          queryAddRow(qryCountry);  
          querySetCell(qryCountry, "Country", "Kenya");
           querySetCell(qryCountry, "CountryID", "3");      
    </cfscript>   
        <cfformgroup type="repeater"  query="qryCountry">                       
            <cfinput type="checkbox" value="{qryCountry.currentItem.CountryID}" name="chk" Label="{qryCountry.currentItem.Country}">                               
        </cfformgroup>
        <cfinput type="submit" name="submit" width="100" value="Submit"  >
    </cfform>

    Hope this will help