J
Joe C.
thank you for reading.
in .net, there are ways to create an array (or arraylist) and bind it
to a dropdownlist. this prevents the use of a loop.
is there an equivalent in javascript?
currently have a large array (3000+ elements), which is then added to
a select object (drop down list) via a loop. firefox takes roughly .
15 seconds to achieve this (that's 1/20th of a second). IE7, on the
other hand, take 6.5 seconds!
firefox script:
for (i = 0; i < arrMain.length - 1; i++) {
document.getElementById('Main_ddCustList').appendChild(new Option
(arrOne, arrTwo));
}
IE script:
for (i = 0; i < arrMain.length - 1; i++) {
document.getElementById('Main_ddCustList').add(new Option(arrOne,
arrTwo));
}
so basically, any way to get IE to load 3000 elements into a select
object (downdownlist) any faster than 6.5 seconds?
any help would be greatly appreciated.
- Joe
in .net, there are ways to create an array (or arraylist) and bind it
to a dropdownlist. this prevents the use of a loop.
is there an equivalent in javascript?
currently have a large array (3000+ elements), which is then added to
a select object (drop down list) via a loop. firefox takes roughly .
15 seconds to achieve this (that's 1/20th of a second). IE7, on the
other hand, take 6.5 seconds!
firefox script:
for (i = 0; i < arrMain.length - 1; i++) {
document.getElementById('Main_ddCustList').appendChild(new Option
(arrOne, arrTwo));
}
IE script:
for (i = 0; i < arrMain.length - 1; i++) {
document.getElementById('Main_ddCustList').add(new Option(arrOne,
arrTwo));
}
so basically, any way to get IE to load 3000 elements into a select
object (downdownlist) any faster than 6.5 seconds?
any help would be greatly appreciated.
- Joe