Thank you for all your suggestions and help. Seth suggested to me
yesterdaty that I start using flex. To be honest I cant wait to get in to
flex but as many of us know where there is a deadline there isn't much
time for leaning. Well the good news is that I was able get my problem to
work yesterday; after reading an article about that very thing; took me a
bit but I was able to make it work.

Here is what I had to do. I had to create two functions, one to look
through the cfgrid to get the data. A second to declare the cfselect
fields, this function is called from the onchange param in the cfgrid.

<cfformitem type="script">
public function selectOption(select:
mx.controls.ComboBox,optionToSelect:String):Void {
    for (var i:Number = 0; i< select.length; i++) {
        if (select.getItemAt([i]).data == optionToSelect){
            select.selectedIndex = i;
            break;
        }
    }
}
function userGridChanged():Void {
        selectOption(SECSTATUSID, AppUsers.selectedItem.SECSTATUSID);
        selectOption(DIV_DEPARTMENTID,
AppUsers.selectedItem.DIV_DEPARTMENTID);      
   
    AppUsers.setFocus();
}

</cfformitem>

Once I did this each select dropdown would change accordingly when I
selected the record in the grid.

Now my next issue is this I would like to display another grid based on
the ID from the previous grid so in old school terms a loop with in a
loop. If anyone has anything please send any suggestions you may have if
not 



-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of [EMAIL PROTECTED]
Sent: Monday, August 27, 2007 8:12 PM
To: [email protected]
Subject: [houcfug] Re: cfgrid data to a cfselect using bind


Ernie,
Laura has some excellent examples on binding here
http://www.asfusion.com/examples/ 

Bind in not supported in CFSELECT in MX7.  CF8 does free up
some binding limitations, but I don't know about CFSELECT.

Mike Nimer has a workaround here
http://www.mikenimer.com/index.cfm?mode=entry&entry=0204C17F-4E22-1671-564
CF4F0B33C3D29
but I haven't personally tried it myself.

Hope this helps.
Don Kerr

----- Original Message Follows -----
From: [EMAIL PROTECTED]
To: [email protected]
Subject: [houcfug] cfgrid data to a cfselect using bind
Date: Mon, 27 Aug 2007 11:51:23 -0500

>I can bind data from a cfgrid to a text box but how would
>you bind that to a select box and one done this before?
>
>Ernie Pena
>UT MD Anderson Cancer Center
>
>>



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Houston ColdFusion 
Users' Group" discussion list.
To unsubscribe, send email to [EMAIL PROTECTED]
For more options, visit http://groups.google.com/group/houcfug?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to