Modul
Isi
Indeks 🔎︎

# Hour Function

Returns the hour from a time value that is generated by the TimeSerial or the TimeValue function.

## Sintaksis:

    Hour (Angka)

## Nilai hasil:

Integer

## Parameter:

Number: Numeric expression that contains the serial time value that is used to return the hour value.

This function is the opposite of the TimeSerial function. It returns an integer value that represents the hour from a time value that is generated by the TimeSerial or the TimeValue function. For example, the expression

Print Hour(TimeSerial(12:30:41))

menghasilkan nilai 12.

## Kode kesalahan:

5 Tidak sah dalam pemanggilan prosedur

## Contoh:

    Sub ExampleHour

    Print "Sekarang adalah jam " & Hour( Now )

    End Sub