A
\A_Michigan_User\
I call this Javascript function with "GetEleNum(this)"
passing it 1 of the elements of a text-box array.
Is there a QUICK way to get the "element #"? I'm currently using this
SLOW code.
(It works... but I need something better/faster.)
function GetEleNum(c)
{
// Given 1 element in this textBox array... what is the array element #?
var i;
for(i=0; i<form1.txtBox.length; i++)
if(form1.txtBox == c) return i;
return 0; // Not found
}
Thanks
passing it 1 of the elements of a text-box array.
Is there a QUICK way to get the "element #"? I'm currently using this
SLOW code.
(It works... but I need something better/faster.)
function GetEleNum(c)
{
// Given 1 element in this textBox array... what is the array element #?
var i;
for(i=0; i<form1.txtBox.length; i++)
if(form1.txtBox == c) return i;
return 0; // Not found
}
Thanks