0

greetings!

anybody know how to convert the month value into word format


for example date = 12/2007
month is december

how to convert this 12 into "december "

is there any command to get the month value into string or word format...or i make may own...

thanks in advance

2
Contributors
1
Reply
4
Views
9 Years
Discussion Span
Last Post by Jx_Man
0

you can change date format :

Ex : Format(Date, "dddd MMMM dd,yyyy")

every days name and month name will be long type

or you can make procedure to convert :

Private Sub Month_Convertion()
   Dim bulan As String
    
    bulan = Month(Date)
    Select Case bulan
    Case 1
        bulan = "Januari"
    Case 2
        bulan = "Februari"
    Case 3
        bulan = "Maret"
    Case 4
        bulan = "April"
    Case 5
        bulan = "Mei"
    Case 6
        bulan = "Juni"
    Case 7
        bulan = "Juli"
    Case 8
        bulan = "Agustus"
    Case 9
        bulan = "September"
    Case 10
        bulan = "Oktober"
    Case 11
        bulan = "November"
    Case 12
        bulan = "Desember"
    End Select
  
  bln = bulan
End Sub

to call this procedure:

Month_Convertion
 lblMonth.Caption = bln

Jery
Best Regards

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.