In a revTalk script, how would I convert the colors I got from the answer color command to result into an HTML-formatted code?
E.g:
I got 255,255,255 in the variable it after using the answer color command, how would I turn that to #FFFFFF which is it's HTML counterpart.
Thank you so much for those who would help me out with this problem.
color convertion
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Posts: 344
- Joined: Tue Feb 24, 2009 6:14 pm
- Contact:
Re: color convertion
shadowslash,
Best regards,
Mark
Code: Select all
put "123,234,241" into myRGB
put "#" into myHex
repeat for each item myItem in myRGB
put baseConvert(myItem,10,16) after myHex
end repeat
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode