RGB Function

Returns a Long integer color value consisting of red, green, and blue components.

SĂŒntaks:


RGB (Red, Green, Blue)

TagastusvÀÀrtus:

Long

Parameeter:

Red: suvaline tÀisarvavaldis, mis tÀhistab liitvÀrvi punase komponenti (0-255).

Green: suvaline tÀisarvavaldis, mis tÀhistab liitvÀrvi rohelise komponenti (0-255).

Blue: suvaline tÀisarvavaldis, mis tÀhistab liitvÀrvi sinise komponenti (0-255).

tip

The color picker dialog helps computing red, green and blue components of a composite color. Changing the color of text and selecting Custom color displays the color picker dialog.


Veakoodid:

5 Vigane protseduuri vÀljakutse

NĂ€ide:


Sub ExampleColor
Dim lVar As Long
    lVar = rgb(128,0,200)
    MsgBox "VĂ€rv " & lVar & " koosneb:" & Chr(13) &_
        "punasest= " & red(lVar) & Chr(13)&_
        "rohelisest= " & green(lVar) & Chr(13)&_
        "sinisest= " & blue(lVar) & Chr(13) , 64,"vÀrvist"
End Sub

Palun toeta meid!