Link to home
Start Free TrialLog in
Avatar of michael123199
michael123199

asked on

point

I retrieve the color of a pixel with the point command...
problem though is that i get a strange large number like 543005 or something like that.

Is it possible to change this number into a html color, like: #FFFFFF for white

??
ASKER CERTIFIED SOLUTION
Avatar of olx
olx

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Actually what you want to do is to PARSE that number into its three parts: Red + 256*(Green+ 256*Blue))

red = 29 = #1D (Hex)
Green = 73 = #49 (Hex)
Blue = 8 = &08 (Hex)

so the hex string would be #08491D or #BBGGRR

you can also get this with the HEX() function:

Hex(543005) = 8491D = #BBGGRR ==> BB=08, GG=49, RR=1D

Arthur Wood