Funkce RGB
Returns a Long integer color value consisting of red, green, and blue components.
Syntaxe:
RGB (Red, Green, Blue)
Návratová hodnota:
Long
Parametr:
Red: Celočíselný výraz reprezentující červenou složku (0-255) barvy.
Green: Celočíselný výraz reprezentující zelenou složku (0-255) barvy.
Blue: Celočíselný výraz reprezentující modrou složku (0-255) barvy.
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.
Příklad:
Sub ExampleColor
Dim lVar As Long
lVar = rgb(128,0,200)
MsgBox "Barva " & lVar & " se skládá z:" & Chr(13) &_
"červená= " & red(lVar) & Chr(13)&_
"zelená= " & green(lVar) & Chr(13)&_
"modrá= " & blue(lVar) & Chr(13) , 64,"barvy"
End Sub