Description
Used to divide two numbers and return a floating-point result.
Syntax
result = number1/number2
The / operator syntax has these parts:
Part |
Description |
result |
Any numeric variable. |
number1 |
Any numeric expression. |
number2 |
Any numeric expression. |
Remarks
The data type of result is usually a Double or a Double variant. The following are exceptions to this rule:
If one or both expressions are Null expressions, result is a Null. Any expression that is Empty is treated as 0.
See Also
Operator Precedence.
Example
This example uses the / operator to perform floating-point division.
MyValue = 10 / 4 ' Returns 2.5. MyValue = 10 / 3 ' Returns 3.333333.