- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-10-2023 05:15 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-10-2023 09:30 AM
Hi @deepika adimu,
Try the below code which is one of the example for change currency and change in country code
i.e., calculated the total price based on quantity and price
Onload Client Script
function onLoad() {
var quantity = g_form.getValue('quantity');
var price = g_form.getValue('price');
var totalPrice = 0;
var getPriceCode = price.split(';');
var priceCode = getPriceCode[0];
var actualPrice = getPriceCode[1];
totalPrice = parseFloat(quantity) * parseFloat(actualPrice);
g_form.setValue('u_total_price',priceCode+';'+totalPrice);
}
If my response helps you to resolve the issue close the question by Accepting solution and hit thumb icon. From Correct answers others will get benefited in future.
Regards,
T Mohan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-10-2023 09:30 AM
Hi @deepika adimu,
Try the below code which is one of the example for change currency and change in country code
i.e., calculated the total price based on quantity and price
Onload Client Script
function onLoad() {
var quantity = g_form.getValue('quantity');
var price = g_form.getValue('price');
var totalPrice = 0;
var getPriceCode = price.split(';');
var priceCode = getPriceCode[0];
var actualPrice = getPriceCode[1];
totalPrice = parseFloat(quantity) * parseFloat(actualPrice);
g_form.setValue('u_total_price',priceCode+';'+totalPrice);
}
If my response helps you to resolve the issue close the question by Accepting solution and hit thumb icon. From Correct answers others will get benefited in future.
Regards,
T Mohan