@clarabellerising Already took these actions but didn't help. I've ended up reinstalling Windows. Now everything works. Hopefully won't have this problem again
Convert the value 1.5K
-
@to-nice you can use JS expressions, as "parseInt", "parseFloat"
parseInt("1.6k")
1
parseFloat("1.6k")
1.6
check, if string has k|K then multiply it by 1000 and so on...var str = "1.6k";
var result = parseFloat(str);
if(str.indexOf("k") != -1){
result = result * 1000;
} -
@BAS-Viet-Nam @clarabellerising WHERE IS ERROR ?
var str = "[[VAR]]"; // Sostituisci con il valore che vuoi convertire
var result = parseFloat(str);if (str.indexOf("k") != -1) {
result = result * 1000;
} else if (str.indexOf("M") != -1) {
result = result * 1000000;
}// Salva il risultato in una variabile globale di BAS
SetGlobalVariable("CONVERTED_VALUE", result.toString()); -
@to-nice in "[[VAR]]"
[[VAR]] is already a variable, you should use just [[VAR]], not "[[VAR]]"
also, im not sure that "else if" exists in js, so, you can just do another if condition
if .indexOf("k"){}
if .indexOf("M"){}
no need to use else -
@clarabellerising in this mode ?
var str = [[VAR]]; // Sostituisci con il valore che vuoi convertire
var result = parseFloat(str);if (str.indexOf("k") != -1) {
result = result * 1000;
}
if (str.indexOf("M") != -1) {
result = result * 1000000;
}
and... how to save result in variable ? thankyouu -
@clarabellerising working perfect !! thankyou