Hi,
I am having trouble using the date functions and wondering if someone can help me.
Basically I want to create a procedure where someone enters a commencement date for there exercise. I store this date in the DB. I then want to retrieve this date and compare it against the days current date then set the current activity for today's dates date in a label.
So something like:
Sub SetWorkoutLabel
If DayTime.Now = (date retrieved from DB) Then
Label1.Text = "Activity1"
End If
If DateTime.Now = (date retrieved from DB, 0, 0, 1) Then
Label1.Text = "Activity2"
End If
End Sub
Obviously this is not correct code just wanted to give you an idea of what I am trying to achieve
I am using an InputDialog for the user to enter a date and storing it as a string. Do I need to format the string when retrieving it from DB or do I need to store it differently?
Any help on this would be greatly appreciated.
Thanx
I am having trouble using the date functions and wondering if someone can help me.
Basically I want to create a procedure where someone enters a commencement date for there exercise. I store this date in the DB. I then want to retrieve this date and compare it against the days current date then set the current activity for today's dates date in a label.
So something like:
Sub SetWorkoutLabel
If DayTime.Now = (date retrieved from DB) Then
Label1.Text = "Activity1"
End If
If DateTime.Now = (date retrieved from DB, 0, 0, 1) Then
Label1.Text = "Activity2"
End If
End Sub
Obviously this is not correct code just wanted to give you an idea of what I am trying to achieve
I am using an InputDialog for the user to enter a date and storing it as a string. Do I need to format the string when retrieving it from DB or do I need to store it differently?
Any help on this would be greatly appreciated.
Thanx