CitectVBA Programming Reference > CitectVBA Function Reference > Conversion Functions > Oct

Oct

Converts a numeric value to a text string representing the octal value of the number.

The Oct function expects the argument Num to be a valid numeric value. It is rounded to nearest whole number before evaluation.

Syntax

Oct(Num)

Num:

An Integer or expression representing a valid numeric value.

Return Value

Returns a text string containing the octal value of the numeric Num value provided in the argument.

Related Functions

Format | Hex | Str | Val

Example

Dim MyOct as String	
MyOct = Oct(4) 'returns "4"
MyOct = Oct(8) 'returns "10"
MyOct = Oct(459) 'returns "713"