lazzerous
11-13-2003, 04:27 PM
I have serveral select boxes that are automatically generated.
They are named as such:
pb[0]
pb[1]
pb[2]
etc...
When trying to reference to these objects directly, I get an error saying what I'm referencing to is 'null or not an object':
for (i = 0; i < 10; i++)
{
var poo = document.form.pb[i].options[document.form.pb[i].options[0].selected].value;
alert(poo);
}
Exact Error:
Error: 'document.form.pb' is null or not an object.
Anyone know why it wont recognize these values?
Thanks you
-=Lazzerous=-
They are named as such:
pb[0]
pb[1]
pb[2]
etc...
When trying to reference to these objects directly, I get an error saying what I'm referencing to is 'null or not an object':
for (i = 0; i < 10; i++)
{
var poo = document.form.pb[i].options[document.form.pb[i].options[0].selected].value;
alert(poo);
}
Exact Error:
Error: 'document.form.pb' is null or not an object.
Anyone know why it wont recognize these values?
Thanks you
-=Lazzerous=-