Represents the colour of a one-colour object, the foreground or background colour of an object with a gradient or patterned
fill. You can set colours to an explicit red-green-blue value (by using the
RGB property) or to a colour in the colour scheme (by using the
SchemeColor property).
Use the
RGB property to set a colour to an explicit red-green-blue value. The following example adds a
comment to cell B2 and then sets the foreground colour for the
comment's
fill.
With Workbook.Sheets[1] do begin
With Range['B2', 'B2'].AddComment('Comment text') do begin
Shape.Fill.ForeColor.RGB := RGB(180, 180, 255);
end;
end;