VBA CLng Function: The CLng function in VBA converts an expression into a Long data type. It returns a long value ranging between -2,147,483,648 and 2,147,483,647.

Syntax

Parameter

Expression (required) – This parameter represents the expression that you want to convert to a Long where the specified expression must be ranging between -2,147,483,648 and 2,147,483,647.

Return

This function returns a Long value after converting the given expression into a long data type. It returns a long ranging between -2,147,483,648 and 2,147,483,647.

Example 1

Output

VBA CLng Function

Example 2

Output

1000

VBA CLng Function

Example 3

Output

VBA CLng Function

Pin It on Pinterest

Share This