KB-51778: Converting a hexadecimal value into decimal.

Question:

How can I convert a hexadecimal value into a decimal one?

Solution:

To do so, you must convert the value into a string, concatenating the text “&H” before it, and use a numeric conversion function. See an example of script below:

v_hexa = 2120
v_hexa_str = “&H” & CStr(v_hexa)
v_decimal = CLng(v_hexa_str)

Print Friendly, PDF & Email

Este artigo foi útil? Was this helpful?

Classificação média - Average rating 0 / 5. Count: 0

Leave a Reply

Your email address will not be published.Required fields are marked *