Microsoft.JScript.GlobalObject.parseInt C# (CSharp) Method

parseInt() private method

private parseInt ( Object @string, Object radix ) : double
@string Object
radix Object
return double
      public static double parseInt(Object @string, Object radix){
        String str = Convert.ToString(@string);
        return Convert.ToNumber(str, true, true, radix);
      }

Usage Example

Example #1
0
        public static double ToNumber(string str)
        {
            if (str == "")
            {
                return(0);
            }

            if (str.IndexOfAny(new char [] { 'x', 'X' }) != -1)
            {
                return(GlobalObject.parseInt(str, null));
            }
            else
            {
                return(GlobalObject.parseFloat(str));
            }
        }
All Usage Examples Of Microsoft.JScript.GlobalObject::parseInt