# Hex Math

## Recommended Posts

ok i see this:

\$result = Hex(1033, 4) ;returns "0409"

but i'm not sure what this has to do with what I need done.

THis is my situation:

\$X = 147000 <-- a hex amount

\$y = 1C6F530 <-- a hex amount

I need to figure out how to subtract 2 hex amount to equal the hex difference.

\$a_hex = \$x - \$y

Need a website: http://www.iconixmarketing.com

##### Share on other sites

ok i see this:

\$result = Hex(1033, 4) ;returns "0409"

but i'm not sure what this has to do with what I need done.

THis is my situation:

\$X = 147000 <-- a hex amount

\$y = 1C6F530 <-- a hex amount

I need to figure out how to subtract 2 hex amount to equal the hex difference.

\$a_hex = \$x - \$y

Autoit interpret hex string as number if this begin with "0x". You can just concatenate it with 0x and then substract as regular number:

\$X = "0x" & "147000"

\$y = "0x" & "1C6F530"

\$a_hex = \$x - \$y

##### Share on other sites

ok great so i don't need special function or anything

Need a website: http://www.iconixmarketing.com

## Create an account

Register a new account

• ### Recently Browsing   0 members

×

• Wiki

• Back

• #### Beta

• Git
• FAQ
• Our Picks
×
• Create New...