Fonction parseInt() WMLScript

La fonction parseInt() retourne un nombre flottant défini par une chaîne.

Syntaxe

n = Lang.parseInt(string)
Composant Description
n Entier retourné par la fonction.
string Une chaîne.

Exemple

var a = Lang.parseInt("2345");
var b = Lang.parseInt("200 m/s");

Résultat

a = 2345
b = 200