<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
<META content="MSHTML 5.00.2920.0" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Thanks a lot for the Help.</FONT></DIV>
<DIV><FONT face=Arial size=2>Actually I managed to solve it and I'm sorry I
didn't post this.</FONT></DIV>
<DIV><FONT face=Arial size=2>I just used eval("0xff").</FONT></DIV>
<DIV><FONT face=Arial size=2>Here the code I used:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>function gethicolor(colorstr)<BR>{</FONT></DIV>
<DIV><FONT face=Arial size=2><BR> red = eval("0x" +
colorstr.slice(1,3));<BR> green = eval("0x" +
colorstr.slice(3,5));<BR> blue = eval("0x" +
colorstr.slice(5,7));</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2> red = red
+ 50;<BR> green = green + 50;<BR> blue = blue +
50;</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2> if(red > 255)red =
255;<BR> if(green > 255)green = 255;<BR> if(blue >
255)blue = 255; <BR> <BR> return ((red * 65536) +
(green * 256) + blue);<BR>}</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Just adding a fixed value to color components
doens't result in a good highlight but...</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Thank's again.</FONT></DIV>
<DIV><FONT face=Arial size=2>Bye.</FONT></DIV>
<BLOCKQUOTE dir=ltr
style="BORDER-LEFT: #000000 2px solid; MARGIN-LEFT: 5px; MARGIN-RIGHT: 0px; PADDING-LEFT: 5px; PADDING-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A href="mailto:peter@brunone.com" title=peter@brunone.com>Peter Brunone</A>
</DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A
href="mailto:javascript@LaTech.edu"
title=javascript@LaTech.edu>javascript@LaTech.edu</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Friday, April 20, 2001 6:10
PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [Javascript] How do I
convert "FF" to 255?</DIV>
<DIV><BR></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2> According to the Netscape
JavaScript reference, you can use escape(var) to get the hexadecimal value,
and unescape(var) to get the decimal value.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<BLOCKQUOTE dir=ltr
style="BORDER-LEFT: #000000 2px solid; MARGIN-LEFT: 5px; MARGIN-RIGHT: 0px; PADDING-LEFT: 5px; PADDING-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A href="mailto:RuiFortes@clix.pt" title=RuiFortes@clix.pt>Rui Fortes</A>
</DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A
href="mailto:javascript@LaTech.edu"
title=javascript@LaTech.edu>javascript@LaTech.edu</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Friday, April 20, 2001 11:23
AM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> [Javascript] How do I convert
"FF" to 255?</DIV>
<DIV><BR></DIV>
<DIV><FONT face=Arial size=2>Hello.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>How can I get an highlighted version of a
color.</FONT></DIV>
<DIV><FONT face=Arial size=2>That is, how can I find the code of a color
wich is a lighter version of another color.</FONT></DIV>
<DIV><FONT face=Arial size=2>I tryed to do this myself but I need, for
instance, to know how to get a number from a string representing an
hexadecimal number.</FONT></DIV>
<DIV><FONT face=Arial size=2>I could then add some value to RGB components
and use RGB(newred, newgreen, newblue) to get that color.</FONT></DIV>
<DIV><FONT face=Arial size=2>I found Hex function that returns a string
representing the hexadecimal convertion of a number.</FONT></DIV>
<DIV><FONT face=Arial size=2>Is there an inverse function to turn a string
into a number?</FONT></DIV>
<DIV><FONT face=Arial size=2>Something like afunc("FF") that returns
255.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Thanks</FONT></DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV> </DIV></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>