This is a kinda funny question!!:D
Its not ajoke either!
Anybody have a cute and easy way to populate a combobox witha date representing the date for firday for the next 3 years?
Printable View
This is a kinda funny question!!:D
Its not ajoke either!
Anybody have a cute and easy way to populate a combobox witha date representing the date for firday for the next 3 years?
I came up with an ugly one here, could probably be done better....
Code:Dim i As Integer
Dim d As Date = Now.Date
For i = 0 To 1100
If d.AddDays(i).DayOfWeek.ToString = "Friday" Then
ComboBox1.Items.Add(d.AddDays(i).ToShortDateString)
End If
Next