faisalsham
Programmer
I have the following function that I'm using to build a query string. however the selectedindex for the listbox is coming out to be 'undefined' not sure what's wrong with the code. please help!
when i use alert(i) to see the value of i, i get undefined in the dialogbox.
thanks
Code:
function BuildQueryString(frmin)
{
var contractPK;
var qs;
var i;
contractPK = frmin.txtContractPK.value;
i= frmin.lstContracts.selectedindex;
qs= "Sales.asp?code=" + contractPK + "&index=" + i;
document.location=qs
}
when i use alert(i) to see the value of i, i get undefined in the dialogbox.
thanks