RGB

Prev Next

General

The RGB function can be used to create a Color from RGB values.

Syntax

You can call the RGB function using the following syntax:

RGB Function Syntax

RGB(<R>, <G>, <B>)

The parameters of the function are:

Name

Description
R The Red value to apply to the color. This needs to be a number between 0 and 255.
G The Green value to apply to the color. This needs to be a number between 0 and 255.
B The Blue value to apply to the color. This needs to be a number between 0 and 255.

Examples

The following example returns a purely red color:

RGB Function Example

RGB(255, 0, 0)