[thelist] hexidecimal in asp
Ken Schaefer
ken at adOpenStatic.com
Tue Jun 1 08:32:20 CDT 2004
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: <david.landy at somerfield.co.uk>
Subject: RE: [thelist] hexidecimal in asp
...
: I had the same problem myself about 3 years ago and this
: worked fine: do all your arithmetic in decimal, converting
: into/out of hex values as required.
:
: David
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
VBScript is quite capable of performing arithmetic operations on hex values
directly, obviating the need to convert to decimal.
<%
Response.Write(&H20 + &HA)
%>
(for example)
There is also a very efficient formula for converting hex -> decimal that a
maths major once gave me - I'll need to dig it out though, if you do need
the final result in decimal.
Cheers
Ken
More information about the thelist
mailing list