I need some help with Jscript on an ASP page,
I make 5 arrays from an SQL Server and want to pick the array from an option box and populate a second option box with that array.
here is what I've done so far...
arrayA
arrayB
arrayC ... arrayE
function onOption1Change(){
strArrayName = document.myform.optionList1.value
Select Case "strArrayName"
Case "arrayA"
for(Items in arrayA){
document.myform.optionList2.options = new option(Item);
}
End Select
I may be going about this completely wrong so I am not adverse to someone telling me a better way. I just need to have this working soon.
Thanks
Peter
I make 5 arrays from an SQL Server and want to pick the array from an option box and populate a second option box with that array.
here is what I've done so far...
arrayA
arrayB
arrayC ... arrayE
function onOption1Change(){
strArrayName = document.myform.optionList1.value
Select Case "strArrayName"
Case "arrayA"
for(Items in arrayA){
document.myform.optionList2.options = new option(Item);
}
End Select
I may be going about this completely wrong so I am not adverse to someone telling me a better way. I just need to have this working soon.
Thanks
Peter