I was hoping maybe someone could help me with a date time problem I am having....I have 2 unbound text boxes that are populated by this code:
Private Sub Form_Open(Cancel As Integer)
Me![Beginning Date] = Date - WeekDay(Date, 4) + 1
Me![Ending Date] = Me![Beginning Date] + 6
End Sub
This returns a beginning date of 2/19/03 and an Ending Date of 2/25/03.(These dates signify our pay week from Wednesday thru Tuesday) My payroll report is based on these dates...which is fine except for one thing...I enter the time worked the next day. (We work 24 hrs a day.)
Here is the problem..on Wednesday mornings I enter the time for Tuesday but my date range has change to reflect the current week. This is the day that I send in the report and need the previous weeks date range. My question is this....
How do I delay the change in the date range until Thursday?
I was hoping there would be an easy way to do this but I am at a loss....
Thanks!!
RookieDev
Private Sub Form_Open(Cancel As Integer)
Me![Beginning Date] = Date - WeekDay(Date, 4) + 1
Me![Ending Date] = Me![Beginning Date] + 6
End Sub
This returns a beginning date of 2/19/03 and an Ending Date of 2/25/03.(These dates signify our pay week from Wednesday thru Tuesday) My payroll report is based on these dates...which is fine except for one thing...I enter the time worked the next day. (We work 24 hrs a day.)
Here is the problem..on Wednesday mornings I enter the time for Tuesday but my date range has change to reflect the current week. This is the day that I send in the report and need the previous weeks date range. My question is this....
How do I delay the change in the date range until Thursday?
I was hoping there would be an easy way to do this but I am at a loss....
Thanks!!
RookieDev