Module
Contents
Index 🔎︎

# Red Function

Returns the Red component of the specified color code.

## Sintaksis:

    Red (ColorNumber As Long)

## Nilai hasil:

Integer

## Parameter:

ColorNumber: Long integer expression that specifies any color code for which to return the Red component.

## Kode kesalahan:

5 Tidak sah dalam pemanggilan prosedur

## Contoh:

    Sub ExampleColor

    Dim lVar As Long

        lVar = rgb(128,0,200)

        MsgBox "Warnanya " & lVar & " terdiri atas:" & Chr(13) &_

            "merah= " & red(lVar) & Chr(13)&_

            "hijau= " & green(lVar) & Chr(13)&_

            "biru= " & blue(lVar) & Chr(13) , 64,"colors"

    End Sub