How to use color?

hI
Im trying to use color variables to change the fillcolor of rectangles but I don’t udnerstand how it works

I tried for example rectangle.fillcolor = color.magenta but I get an error

pls can u post an example of setting the colors of a control using COLOR
thanks a lot

rgds

Color.magenta returns the magenta component of the color, it does not return a color object for the color magenta. Instead use the RGB/HSV/CMY functions to define your colors, or the &c color literal.

http://documentation.xojo.com/index.php/RGB
http://documentation.xojo.com/index.php/HSV
http://documentation.xojo.com/index.php/CMY
http://documentation.xojo.com/index.php/%26c