OK, I have tried all possible avenues to do this.
Simply put, I am needing to change the value of a text field, based on the radio button selection of the user.
They can select to pay the total amount (which is already populated in another field) or they can choose to be billed later, which makes that field be equal to zero. I am not a Javascript expert, but if I can get a bit of help, I will be able to finish this form.
Here's what I have:
var adpayment = this.getField("advertising_payment");//advertising_payment if the name of the radio button field
var selection = adpayment.value;
var totaladv = this.getField("total_from_page_10"); //this is the total payment
if
(selection.value == "invoicelater")
{event.value = 0}
else
{event.value = totaladv.value};
I have another case where they select the radio button and also from a pull down menu so the case would be an "AND" statement. However, since my other example doesn't work, I know I am not doing it correctly.
Your help is appreciated.
The evaluation should read
if (selection == "invoicelater")
and that should work out (if one of the return values in adpayment is actually "invoicelater".
Hope this can help.
Max.