metalface
12-07-2006, 03:29 PM
I've searched high and low to find a solution to this problem I'm having with Select controls. I'd like to be able to be able to change the status or visibility of a counterpart select control depending on the choice I make with the first select control I change.
Here's the example: http://appsrv.pace.edu/specialevents/deans.cfm
For instance, I have two select boxes (#1 and #2 for this example). Say I have several choices in a #1 like Apples, Oranges, Bananas. If I were to select Apples I want the #2 Select box to become enabled. The default for #2 would be disable (grayed out). Then say if I change my mind for the #1 select and choose Bananas instead. The #2 select should then gray out. Any help appreciated.
<cfform name="Performance" timeout="500" height="800" width="800" format="flash" skin="haloSilver" action="action.cfm" method="post">
<cfselect name="Title" label="Title" width="200" tooltip="Please enter appropiate title." required="Yes" >
<option>Select</option>
<option value = "Asso. & Asst. Deans" onchange="object.removeAttribute('disabled')">Asso. & Asst. Deans</option>
<option value = "Asso. & Asst. Provost & VPs">Asso. & Asst. Provost & VPs</option>
<option value = "Campus Directors">Campus Directors</option>
<option value = "Dean for Students">Dean for Students</option>
<option value = "Executive Directors">Executive Directors</option>
<option value = "Faculty">Faculty</option>
<option value = "Officers">Officers</option>
<option value = "School Deans">School Deans</option>
<option value = "University Directors">University Directors</option>
<cfselect name="School" width="200" required="Yes" enabled="false" >
<option>Select</option>
<option value = "Dyson">Dyson</option>
<option value = "Education">Education</option>
<option value = "Law">Law</option>
<option value = "Lienhard">Lienhard</option>
<option value = "Lubin">Lubin</option>
<option value = "Seidenberg">Seidenberg</option>
</cfselect>
The problem is similar to this I think: http://www.codingforums.com/showthread.php?t=86657&highlight=select+control+enable
Here's the example: http://appsrv.pace.edu/specialevents/deans.cfm
For instance, I have two select boxes (#1 and #2 for this example). Say I have several choices in a #1 like Apples, Oranges, Bananas. If I were to select Apples I want the #2 Select box to become enabled. The default for #2 would be disable (grayed out). Then say if I change my mind for the #1 select and choose Bananas instead. The #2 select should then gray out. Any help appreciated.
<cfform name="Performance" timeout="500" height="800" width="800" format="flash" skin="haloSilver" action="action.cfm" method="post">
<cfselect name="Title" label="Title" width="200" tooltip="Please enter appropiate title." required="Yes" >
<option>Select</option>
<option value = "Asso. & Asst. Deans" onchange="object.removeAttribute('disabled')">Asso. & Asst. Deans</option>
<option value = "Asso. & Asst. Provost & VPs">Asso. & Asst. Provost & VPs</option>
<option value = "Campus Directors">Campus Directors</option>
<option value = "Dean for Students">Dean for Students</option>
<option value = "Executive Directors">Executive Directors</option>
<option value = "Faculty">Faculty</option>
<option value = "Officers">Officers</option>
<option value = "School Deans">School Deans</option>
<option value = "University Directors">University Directors</option>
<cfselect name="School" width="200" required="Yes" enabled="false" >
<option>Select</option>
<option value = "Dyson">Dyson</option>
<option value = "Education">Education</option>
<option value = "Law">Law</option>
<option value = "Lienhard">Lienhard</option>
<option value = "Lubin">Lubin</option>
<option value = "Seidenberg">Seidenberg</option>
</cfselect>
The problem is similar to this I think: http://www.codingforums.com/showthread.php?t=86657&highlight=select+control+enable