esthera
09-03-2006, 10:11 AM
can someone help me with teh following function I am trying to write.
my code:
function PaymentsDelete(i){
if(document.payments.deleteme.checked){
alert('delete');
myfield=amount+i;
documents.payments.myfield.value=0;
}
}
What I want this to do is to take the i passed in and set the field in the payments form name amount and i to 0.
In other words if i is 1 then the script should set payments.amount1=0.
can someone help me get this working. Now it seems to be ignoring the statement.
my code:
function PaymentsDelete(i){
if(document.payments.deleteme.checked){
alert('delete');
myfield=amount+i;
documents.payments.myfield.value=0;
}
}
What I want this to do is to take the i passed in and set the field in the payments form name amount and i to 0.
In other words if i is 1 then the script should set payments.amount1=0.
can someone help me get this working. Now it seems to be ignoring the statement.