Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Generating 256 color choices
Message
 
 
To
06/04/2002 22:36:25
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00605952
Message ID:
00641897
Views:
28
The code looks okey to me. Looks like the window isn't high enough to show all rows. Can you add vertical scrollbar to it?

>>The code in the message generates HTML table with 16 columns and 17 rows. Your code generates table with 8 columns and 28 rows. 6 rows are missing.
>
>Yes, I thought it would have been easier to follow from the original code that was given. Here is what I use:
>
>
>lcHtml=lcHtml+'<TABLE CELLSPACING=0 CELLPADDING=0 ID=ToCenter><TR>'
>lnPerRow = 8
>Store 255/(2^3-1) to lnRedInc, lnGreenInc
>lnBlueInc = 255/(2^2-1)
>lnShp=0
>For blue = 0 to 2^2-1
>   For green = 0 to 2^3-1
>      For red = 0 to 2^3-1
>         lnShp  = lnShp+1
>         lnRed = round(red * lnRedInc,0)
>         lnGreen = round(green * lnGreenInc,0)
>         lnBlue = round(blue * lnBlueInc,0)
>         lcWebColor = right(trans(rgb(lnBlue,lnGreen,lnRed),'@0'),6)
>         lcHtml=lcHtml+iif((lnShp-1)%lnPerRow=0,'<TR>','')+;
>          '<TD bgcolor=#'+lcWebColor'">...'
>      Endfor
>   Endfor
>Endfor
>lcHtml=lcHtml+'</TABLE>'
>
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform