Categories | Question details Back To List | ||
Getting contenst of filtered lists I currently have a grid with a number of attached headers as #select_filter. Is it possible to programatically, via javascript, iterate through the values in the select list in order to populate a different select list on the same page? Upon examining the DOM, it doesnt appear that either a name or id is available. For example, on viewing the DOM for one column I see: <div class="hdrcell filter"> <select style="width: 90%; font-size: 8pt; font-family: Tahoma;"> <option value=""></option> <option value="AACC-Reg Admin">AACC-Reg Admin</option> <option value="APC-Float">APC-Float</option> <option value="APC-I">APC-I</option> </select> </div> Since there is no id I cant use getElementById to get ahold of the select object then the values. Is this possible? Answer posted by dhxSupport on Mar 16, 2009 08:51 To get object of a certaing select box in the header you can use: var obj=grid.hdr.getElementsByTagName("SELECT")[0]; Answer posted by Eric Stauffer on Mar 16, 2009 10:07 Perfect. Thanks for the quick reply. Where might I find a list of methods / properties in the obj object created above. I assumed (correctly) the value property but are there others that might be valuable. Answer posted by dhxSupport on Mar 17, 2009 04:30 obj is a reference to the ordinary select box. It hasn't any special methods/properties. |