Public Function GenMonthThai(ByVal intMonth As Integer, ByVal intParameter As Integer)
Dim strMonth As String = String.Empty
Select Case intMonth.ToString
Case "1"
If intParameter = 1 Then
strMonth = "ม.ค"
ElseIf intParameter = 2 Then
strMonth = "มกราคม"
End If
Case "2"
If intParameter = 1 Then
strMonth = "ก.พ"
ElseIf intParameter = 2 Then
strMonth = "กุมภาพันธ์"
End If
Case "3"
If intParameter = 1 Then
strMonth = "มี.ค"
ElseIf intParameter = 2 Then
strMonth = "มีนาคม"
End If
Case "4"
If intParameter = 1 Then
strMonth = "เม.ษ"
ElseIf intParameter = 2 Then
strMonth = "เมษายน"
End If
Case "5"
If intParameter = 1 Then
strMonth = "พ.ค"
ElseIf intParameter = 2 Then
strMonth = "พฤษภาคม"
End If
Case "6"
If intParameter = 1 Then
strMonth = "มิ.ย"
ElseIf intParameter = 2 Then
strMonth = "มิถุนายน"
End If
Case "7"
If intParameter = 1 Then
strMonth = "ก.ค"
ElseIf intParameter = 2 Then
strMonth = "กรกฏาคม"
End If
Case "8"
If intParameter = 1 Then
strMonth = "ส.ค"
ElseIf intParameter = 2 Then
strMonth = "สิงหาคม"
End If
Case "9"
If intParameter = 1 Then
strMonth = "ก.ย"
ElseIf intParameter = 2 Then
strMonth = "กันยายน"
End If
Case "10"
If intParameter = 1 Then
strMonth = "ต.ค"
ElseIf intParameter = 2 Then
strMonth = "ตุลาคม"
End If
Case "11"
If intParameter = 1 Then
strMonth = "พ.ย"
ElseIf intParameter = 2 Then
strMonth = "พฤศจิกายน"
End If
Case "12"
If intParameter = 1 Then
strMonth = "ธ.ค"
ElseIf intParameter = 2 Then
strMonth = "ธันวาคม"
End If
End Select
Return strMonth
End Function
Dim strDate = "10-Jan-2011"
Me.lbl.Text = Day(strDate) & " - " & GenMonthThai(Month(strDate),1) & " - " & Year(strDate)