Filesize: 1.8 KiB
Platform(s): Windows®


Windows Script Host

WSC.nConv is Windows Scripting Component for number-to-letters (BCS languages, Bosnian/Croatian/Serbian) and arabic-to-roman-numerals conversion. nConv has only two methods and is easy to use and implement in different Windows Script languages (JScript, VBScript).


Register WSCWindows Scripting Component must be registered on the end user system, in order for windows script to be able to access it. Registration is easily achieved by right clicking the WSC file in Windows Explorer, and choosing "Register" from the context menu. Windows will then enter information about the component in the registry, and enable all windows scripts (whether they are written in JScript or VBScript) to create instances of it and use it's methods. Syntax is almost the same, so following JScript example can be easily rewritten in VBScript.


There is a <trynConv.js> file in ZIP distribution which demonstrates quickly the use of the class. Class is used in the following way:

// nConv WSC Test
var nConv = WScript.CreateObject('WSC.nConv');
// n2L Test
num = 861475.13;
str = nConv.n2L(num);
WScript.Echo(num+' should be:\n'+str);
// n2R Test
num = 1888;
str = nConv.n2R(num);
WScript.Echo(num+'. should be:\n'+str);

Class has no properties as has following methods:

  • WSC.nConv.n2L(number)
    This method returns string representation of number in BCS languages (Bosnian/Croatian/Serbian).

  • WSC.nConv.n2R(number)
    This method returns number converted to roman numerals representation.