Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Change days and months

I have the following code, but I want to change the days e.g. "Friday = Vrydag" and the months e.g "October = Oktober". I want to know how I can change the language.

Here is my code

Imports System.Globalization
Imports System.Threading

Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick

Dim dt As DateTime = DateTime.Now
Dim myformat() As String = {"dddd dd MMMM yyyy"}
Dim mydate As String
Dim I As Integer
Thread.CurrentThread.CurrentCulture = New CultureInfo("af-ZA")
lblDatum.Text = dt.ToString(myformat(0), DateTimeFormatInfo.InvariantInfo)
Dim dt1 As DateTime = DateTime.Now
Dim myformat1() As String = {"HH : MM : sss"}
Dim mydate1 As String
Dim J As Integer
lbltyd.Text = dt1.ToString(myformat1(0), DateTimeFormatInfo.InvariantInfo)
End Sub



Thanks
Sign In or Register to comment.