BiggerNumberMBS methods

Online Documentation   -   Statistics   -   FAQ   -   Plugin Parts (All, Dependencies)   -   Class hierarchy

New in Version 22.2 22.3 22.4 22.5 23.0 23.1 23.2 23.3 23.4 23.5 24.0 24.1

The list of the   topics,   classes,   interfaces,   controls,   modules,   global methods by category,   global methods by name,   screenshots,   licenses   and   examples.

Platforms to show: All Mac Windows Linux Cross-Platform

Back to BiggerNumberMBS class.

Next items

BiggerNumberMBS.Abs as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Queries absolute value.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(-123)
dim z as BiggerNumberMBS = o.Abs

MsgBox z.StringValue

Removes sign.

See also:

BiggerNumberMBS.Add(other as BiggerNumberMBS, round as boolean = true) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Adds a number.
Example
dim x as new BiggerNumberMBS(2)
dim d as new BiggerNumberMBS(3)
dim p as BiggerNumberMBS = x.Add(d)

MsgBox p.StringValue // shows 5

BiggerNumberMBS.BitAnd(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates bitwise AND operation.
Example
dim x as new BiggerNumberMBS(17)
dim y as new BiggerNumberMBS(16)
dim r as BiggerNumberMBS = x.BitAnd(y)

MsgBox r.StringValue

BiggerNumberMBS.BitOr(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates bitwise or operation.
Example
dim x as new BiggerNumberMBS(17)
dim y as new BiggerNumberMBS(16)
dim r as BiggerNumberMBS = x.BitOr(y)

MsgBox r.StringValue

BiggerNumberMBS.BitXOr(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates bitwise xor operation.
Example
dim x as new BiggerNumberMBS(17)
dim y as new BiggerNumberMBS(16)
dim r as BiggerNumberMBS = x.BitXOr(y)

MsgBox r.StringValue

BiggerNumberMBS.Ceil as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 21.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
This function returns a value representing the smallest integer that is greater than or equal to x.
Example
Dim c As New BiggerNumberMBS(-3.7)
Dim d As BiggerNumberMBS = c.Ceil

MsgBox d // shows -3

e.g.
Ceil(-3.7) = -3
Ceil(-3.1) = -3
Ceil(-3.0) = -3
Ceil(4.0) = 4
Ceil(4.2) = 5
Ceil(4.8) = 5

BiggerNumberMBS.Constructor

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Initialize the number with zero value.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS
MsgBox o.StringValue

See also:

BiggerNumberMBS.Constructor(other as BiggerNumberMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Initialize the number with other value.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(2.5)
dim c as BiggerNumberMBS = new BiggerNumberMBS(o)

MsgBox c.StringValue

See also:

BiggerNumberMBS.Constructor(value as Currency)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Creates a new number object with a currency object.
Example
dim v as Currency = 123.456
dim b as new BiggerNumberMBS(v)
MsgBox b.StringValue

See also:

BiggerNumberMBS.Constructor(value as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Initialize the number with double value.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(2.5)
MsgBox str(o.DoubleValue)+" = "+str(o.StringValue)#

See also:

BiggerNumberMBS.Constructor(value as Int32)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Creates a new number with a 32-bit integer.
Example
dim v as Int32 = 123
dim b as new BiggerNumberMBS(v)
MsgBox b.StringValue

See also:

BiggerNumberMBS.Constructor(value as Int64)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Creates a new number with a 64-bit integer.
Example
dim v as Int64 = 123
dim b as new BiggerNumberMBS(v)
MsgBox b.StringValue

See also:

BiggerNumberMBS.Constructor(value as Single)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Creates a new number with a 32-bit floating point number.
Example
dim v as Single = 123
dim b as new BiggerNumberMBS(v)
MsgBox b.StringValue

See also:

BiggerNumberMBS.Constructor(value as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Initialize the number with string value.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS("123.456")
MsgBox o.StringValue

See also:

BiggerNumberMBS.Constructor(value as UInt32)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Creates a new number with an unsigned 32-bit integer.
Example
dim v as UInt32 = 123
dim b as new BiggerNumberMBS(v)
MsgBox b.StringValue

See also:

BiggerNumberMBS.Constructor(value as UInt64)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Creates a new number with an unsigned 32-bit integer.
Example
dim v as UInt64 = 123
dim b as new BiggerNumberMBS(v)
MsgBox b.StringValue

See also:

BiggerNumberMBS.Divide(other as BiggerNumberMBS, round as boolean = true) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Divides the number.
Example
dim x as new BiggerNumberMBS(8)
dim d as new BiggerNumberMBS(2)
dim p as BiggerNumberMBS = x.Divide(d)

MsgBox p.StringValue // shows 4

BiggerNumberMBS.Equals(other as BiggerNumberMBS) as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Checks if two numbers are the same.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(123)
dim z as BiggerNumberMBS = new BiggerNumberMBS(123)

if o.Equals(z) then
MsgBox "equal"
else
Break // error
end if

Returns true if equal.

BiggerNumberMBS.Floor as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Removes any fraction part.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(2.3)
dim s as BiggerNumberMBS = o.Floor

MsgBox s.StringValue

dim a as BiggerNumberMBS = new BiggerNumberMBS(-2.3)
dim b as BiggerNumberMBS = a.Floor

MsgBox b.StringValue

BiggerNumberMBS.Frac as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Extracts the fraction part.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(2.5)
dim s as BiggerNumberMBS = o.Frac

MsgBox s.StringValue

dim a as BiggerNumberMBS = new BiggerNumberMBS(-2.5)
dim b as BiggerNumberMBS = a.Frac

MsgBox b.StringValue

BiggerNumberMBS.GetStringValue(Base as Integer = 10, scientific as boolean = false, scientificFrom as Integer = 15, round as Integer = -1, TrimZeros as Boolean = true, comma as String = ".") as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Queries string value.
Example
dim o as new BiggerNumberMBS(1234)

// show as hex
MsgBox o.GetStringValue(16)

// show as number with comma and 3 digits
dim z as new BiggerNumberMBS(12.345)
MsgBox z.GetStringValue(10, false, 15, 3, true, ",")

Base: The base of the number system. Normally 10, but also 16 for hex is common.
scientific: Whether to use scientific notation.
scientificFrom: How many digits we show.
Round: Whether to round to n digits.
TrimZeros: Whether to trim unneeded zeros.
comma: The character to use as decimal dot.

See also:

BiggerNumberMBS.GetStringValue(Conversion as BigNumberConversionMBS) as String   New in 24.0

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 24.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Queries string value.
Example
Dim o As New BiggerNumberMBS(1234567.890)

Dim conv As New BigNumberConversionMBS
conv.Comma = ","
conv.Group = "'"
conv.Scientific = False
conv.Round = 3

Dim s1 As String = o.GetStringValue(conv)
// 1'234'567,89

conv.Comma = "."
conv.Group = ","

Dim s2 As String = o.GetStringValue(conv)
// 1,234,567,89

conv.Comma = ","
conv.Group = "'"
conv.Scientific = True

Dim s3 As String = o.GetStringValue(conv)
// 1,235e+6

Break

See also:

BiggerNumberMBS.Modulate(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Modulates a number.
Example
dim x as new BiggerNumberMBS(17)
dim y as new BiggerNumberMBS(3)
dim r as BiggerNumberMBS = x.Modulate(y)

MsgBox r.StringValue

Similar to mod keyword in Xojo.

BiggerNumberMBS.Modulate2 as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Modulates by 2.
Example
dim x as new BiggerNumberMBS(8)
dim y as new BiggerNumberMBS(9)

MsgBox str(x.Modulate2)+" "+str(y.Modulate2)

Returns 0 or 1.

BiggerNumberMBS.Multiply(other as BiggerNumberMBS, round as boolean = true) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Multiplies two numbers.
Example
dim x as new BiggerNumberMBS(8)
dim d as new BiggerNumberMBS(2)
dim p as BiggerNumberMBS = x.Multiply(d)

MsgBox p.StringValue // shows 16

See also:

BiggerNumberMBS.Multiply(value as Integer) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Multiply by an integer.
Example
dim x as new BiggerNumberMBS(2)
dim p as BiggerNumberMBS = x.Multiply(3)

MsgBox p.StringValue // shows 6

See also:

BiggerNumberMBS.Multiply(value as UInt32) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Multiply by an unsigned integer.
Example
dim x as new BiggerNumberMBS(17)
dim r as BiggerNumberMBS = x.Multiply(3)

MsgBox r.StringValue

See also:

BiggerNumberMBS.Negate as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Negates the number.
Example
dim o as BiggerNumberMBS = new BiggerNumberMBS(123)
dim z as BiggerNumberMBS = o.Negate

MsgBox z.StringValue

BiggerNumberMBS.Operator_Add(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Adds a number.
Example
dim a as new BiggerNumberMBS(3)
dim b as new BiggerNumberMBS(4)

// add
dim c as BiggerNumberMBS = a + b

MsgBox c.StringValue

BiggerNumberMBS.Operator_AddRight(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Adds a number.
Example
dim a as new BiggerNumberMBS(3)
dim b as new BiggerNumberMBS(4)

// add
dim c as BiggerNumberMBS = a + b

MsgBox c.StringValue

BiggerNumberMBS.Operator_Compare(other as BiggerNumberMBS) as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Compares two numbers.
Example
dim a as new BiggerNumberMBS(1.2)
dim b as new BiggerNumberMBS(1.2)
dim c as new BiggerNumberMBS(1.3)

if a = b then
// ok
else
break
end if

if a < c then
// ok
else
Break
end if

if c > b then
// ok
else
break
end if

BiggerNumberMBS.Operator_Convert as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Converts big number to string automatically.
Example
dim b as new BiggerNumberMBS
dim n as Double = 5

// convert from double to big number automatically
b = n

// convert to string automatically
MsgBox b

See also:

BiggerNumberMBS.Operator_Convert(value as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Converts a string to a big number.
Example
dim b as new BiggerNumberMBS
dim n as string = "5"

// convert from string to big number automatically
b = n

// convert to double automatically
dim d as Double = b
MsgBox str(d)

See also:

BiggerNumberMBS.Operator_Divide(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Divides two numbers.
Example
dim a as new BiggerNumberMBS(9.3)
dim b as new BiggerNumberMBS(3.0)

dim r as BiggerNumberMBS = a / b

MsgBox r.StringValue

BiggerNumberMBS.Operator_DivideRight(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Divides two numbers.

BiggerNumberMBS.Operator_IntegerDivide(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates an integer divide.
Example
dim a as new BiggerNumberMBS(9.3)
dim b as new BiggerNumberMBS(3.0)

dim r as BiggerNumberMBS = a \ b

MsgBox r.StringValue

Same as normal divide, but removes fraction part.

BiggerNumberMBS.Operator_IntegerDivideRight(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates an integer divide.

Same as normal divide, but removes fraction part.

BiggerNumberMBS.Operator_Modulo(other as BiggerNumberMBS) as BiggerNumberMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Math MBS DataTypes Plugin 20.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates the modulo of two numbers.
Example
dim a as new BiggerNumberMBS(9.3)
dim b as new BiggerNumberMBS(3.0)

dim r as BiggerNumberMBS = a mod b

MsgBox r.StringValue

Next items

The items on this page are in the following plugins: MBS DataTypes Plugin.


💬 Ask a question or report a problem