Convert a Hexadecimal Number to a Base 10 Value

Category:
Dates and Math
Type:
Snippets
Difficulty:
Beginning
Author:
Bob Hodge

Version Compatibility:

More information:
This function will convert a Hexadecimal number to a long integer; i.e., it is the converse of the Hex$ function in VB.

Example:

num = HexToLong("16f4A")

num will have a value 94026.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: