Quantcast
Channel: Adobe Community: Message List
Viewing all articles
Browse latest Browse all 110690

Re: populate textbox with radio box output

$
0
0

If I understand what you're trying to achieve, the custom calculation script for the text field could be:

 

// Custom calculation script for text field

(function () {

 

    // Get the field values

    var v1 = getField("CHESTQTY").value;

    var v2 = getField("BACKQTY").value;

 

    // Create a variable for the sum

    var sum = 0;

 

    // Add 35 to the sum if any of the radio buttons is selected

    if (v1 !== "Off") sum += 35;

 

    // Add 85 to the sum if any of the other radio buttons is selected

    if (v2 !== "Off") sum += 85;

 

    // Set this field's value to the sum

    event.value = sum;

 

})();


Viewing all articles
Browse latest Browse all 110690

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>